Open-source platform to map fruit trees across Brazil, connecting people with accessible fruit trees in their communities.
Fruit Map is an open-source platform to map fruit trees across Brazil, connecting people with accessible fruit trees in their communities. The project aims to create a mobile-responsive PWA application that allows users to discover, share, and locate fruit trees with seasonal information. It's a community-driven foraging map with location search, reviews, and a mobile-friendly design.
- Interactive map of fruit trees across Brazil using Leaflet.js and OpenStreetMap
- Seasonal information by geographic region
- Community-driven content contribution
- Mobile-responsive PWA design
- Secure user authentication with JWT
- User reviews and ratings
- Location-based search with radius filtering
Frontend:
- React.js with TypeScript
- Leaflet.js for interactive maps
- React Leaflet for React components
- Axios for HTTP client
- React Router for routing
- CSS3 with responsive design (Flexbox/Grid)
Backend:
- Node.js with Express.js
- TypeScript
- PostgreSQL with PostGIS for geospatial data
- JWT-based authentication
- BCrypt for password hashing
Additional Technologies:
- Redis for caching
- Multer for file uploads
- Winston for logging
- Joi for input validation
- Helmet for security headers
- CORS support
- Rate limiting with express-rate-limit
The project follows a three-tier architecture:
- Frontend Layer - React PWA client with map interface
- Backend Layer - Node.js/Express API server with multiple services
- Data Layer - PostgreSQL database with PostGIS extension
This project uses AI agent guidelines for development, which are stored in the agentic/ directory:
agentic/AGENTIC.md- Behavioral guidelines for agentsagentic/WORKFLOW.md- Development workflow for Fruit Map projectagentic/POSTPR.md- Post-PR approval process documentationagentic/QWEN.md- Qwen-specific directivesagentic/GEMINI.md- Gemini-specific guidelinesagentic/STYLEGUIDE.md- Code style guide for Fruit Map
- Node.js (v18+)
- PostgreSQL with PostGIS extension
- Git
-
Clone the repository:
git clone https://github.com/lfgranja/fruitmap.git cd fruitmap -
Install backend dependencies:
cd backend npm install -
Install frontend dependencies:
cd ../frontend npm install -
Set up environment variables:
# In the backend directory cp .env.example .env # Edit the .env file with your configuration
-
Set up the database:
# Make sure PostgreSQL is running # Create database and run migrations cd backend npm run migrate
-
Run the development servers:
# Terminal 1: Start the backend cd backend npm run dev # Terminal 2: Start the frontend cd frontend npm start
npm run dev- Start development server with nodemonnpm run build- Compile TypeScript to JavaScriptnpm run migrate- Run database migrationsnpm run test- Run testsnpm run lint- Run linting
Complete project documentation is available in the docs/ directory:
docs/System-Architecture.mddocs/Database-Schema.mddocs/MVP-and-Requirements.mddocs/Technology-Stack.md- And more in the
docs/directory
This project is licensed under the MIT License - see the LICENSE file for details.