How ayushidarode/cropkart works
CropKart is a farmer-to-buyer produce marketplace. Farmers publish crop listings; buyers discover and inspect crops, compare reference prices, negotiate, and request samples or bulk orders; farmers manage requests, and buyers can arrange transport and review completed orders. The React app uses a shared API client to reach an Express backend, whose sampled implementation keeps application data in memory. Major documented capabilities such as nearby discovery, dashboards, messaging, notifications, and assistant support are represented; backend details are concentrated in one source file, so internal handler wiring is not inferred.
Main entry points: App.jsx App routing · api.js API client · index.js Express API · CropDetailPage.jsx Crop details
Components 24
Web experience
- App routing
frontend/src/App.jsx - Auth context
frontend/src/AuthContext.jsx - API client
frontend/src/api.js - Farmer dashboard
frontend/src/pages/FarmerDashboard.jsx - Buyer dashboard
frontend/src/pages/BuyerDashboard.jsx - Admin dashboard
frontend/src/pages/AdminDashboard.jsx
Crop discovery
- Marketplace
frontend/src/pages/MarketplacePage.jsx - Nearby crops
frontend/src/pages/NearbyPage.jsx - Crop details
frontend/src/pages/CropDetailPage.jsx - Farmer profile
frontend/src/pages/FarmerProfilePage.jsx
Orders and engagement
- Purchase requests
frontend/src/pages/CropDetailPage.jsx - Negotiation chat
frontend/src/components/NegotiationChat.jsx - Favorites
frontend/src/pages/FavoritesPage.jsx
Backend services
- Express API
backend/index.js - In-memory state
backend/index.js - Image uploads
backend/public/uploads - Market insights
backend/index.js - Messaging service
backend/index.js - Notifications
backend/index.js - Reviews
backend/index.js - Crop assistant
backend/index.js
Other components
- Farmer
- Buyer
- Admin
Connections 32
- Farmer → App routing: uses
- Buyer → App routing: uses
- Admin → App routing: uses
- App routing → Auth context: provides session
- App routing → Marketplace: routes to
- App routing → Nearby crops: routes to
- App routing → Crop details: routes to
- App routing → Farmer dashboard: routes to
- App routing → Buyer dashboard: routes to
- App routing → Admin dashboard: routes to
- App routing → Favorites: routes to
- Marketplace → API client: requests crops
- Nearby crops → API client: requests nearby crops
- Crop details → API client: loads crop data
- Crop details → Purchase requests: initiates orders
- Purchase requests → API client: submits requests
- Negotiation chat → API client: sends and loads messages
- Farmer dashboard → API client: manages listings and requests
- Buyer dashboard → API client: manages orders
- Favorites → API client: uses favorites API
- API client → Express API: calls API
- Auth context → API client: authenticates through
- Express API → In-memory state: reads and updates
- Express API → Image uploads: stores images
- Express API → Market insights: serves price insights
- Express API → Messaging service: handles message routes
- Express API → Notifications: serves notifications
- Express API → Reviews: handles reviews
- Express API → Crop assistant: handles assistant queries
- Crop details → Market insights: loads comparison
- Farmer dashboard → Crop assistant: queries assistant
- Buyer dashboard → Crop assistant: queries assistant