Agridom is a modern agricultural web application designed to provide users with useful agricultural information and data-driven insights. The project is built with React, TypeScript, Vite, Tailwind CSS, and Supabase.
- 🌱 Agricultural information and resources
- 🌾 Crop-related data and recommendations
- 📊 Agricultural data visualization
- 🌧️ Rainfall and temperature datasets
- 🧪 Pesticide-related agricultural data
- 📈 Crop yield information
- 🔐 Supabase integration
- 🎨 Responsive user interface
- ⚡ Fast development and production builds using Vite
- React
- TypeScript
- Vite
- React Router
- Tailwind CSS
- Radix UI
- React Hook Form
- Zod
- Recharts
- Lucide React
- Supabase
The project includes agricultural datasets in the backend_agridom directory, including:
Crop_recommendation.csvpesticides.csvrainfall.csvtemp.csvyield.csvyield_df.csv
agridom-project/
├── backend_agridom/
│ ├── Crop_recommendation.csv
│ ├── pesticides.csv
│ ├── rainfall.csv
│ ├── temp.csv
│ ├── yield.csv
│ └── yield_df.csv
├── public/
├── src/
├── supabase/
├── .env
├── .gitignore
├── Index.tsx
├── package.json
├── package-lock.json
├── tailwind.config.ts
├── vite.config.ts
├── tsconfig.json
└── README.md
Before running the project, make sure you have the following installed:
- Node.js 18 or later
- npm
- Git
You can verify your installations with:
node --version
npm --version
git --versiongit clone https://github.com/JohnDakin/agridom-project.gitcd agridom-projectnpm installCreate a .env file in the project root.
Add the environment variables required by the application, for example:
VITE_SUPABASE_URL=your_supabase_url
VITE_SUPABASE_ANON_KEY=your_supabase_anon_keyReplace the placeholder values with your actual Supabase project credentials.
Important: Never commit your
.envfile or expose private credentials in your GitHub repository.
Start the application with:
npm run devVite will start the development server. Open the URL displayed in your terminal, typically:
http://localhost:5173
Create a production build with:
npm run buildFor a development-mode build:
npm run build:devRun ESLint with:
npm run lintAfter creating a production build, run:
npm run previewEnvironment variables are required for services such as Supabase.
The following files should never be committed:
.env
.env.local
.env.development
.env.production
.env.test
Create your own local .env file when setting up the project.
The project's JavaScript and TypeScript dependencies are managed through package.json and package-lock.json.
Install them with:
npm installDo not use pip install -r requirements.txt for the React frontend.
A typical development workflow is:
git clone https://github.com/JohnDakin/agridom-project.git
cd agridom-project
npm install
# Create and configure .env
npm run devContributions are welcome.
- Fork the repository.
- Create a feature branch.
git checkout -b feature/your-feature- Make your changes.
- Run the linter.
npm run lint- Build the project.
npm run build- Commit your changes.
git add .
git commit -m "Add your feature"- Push your branch.
git push origin feature/your-feature- Open a pull request.
Never commit passwords, API keys, Supabase credentials, private tokens, or other secrets to Git.
Environment files such as .env should remain local and be excluded using .gitignore.
If an .env file containing real credentials has already been committed, removing it from .gitignore is not enough. The file must also be removed from Git tracking and any exposed credentials should be rotated.
Add the project's license information here if a license is added to the repository.
John Dakin
GitHub: JohnDakin