A full-stack food delivery application with user authentication, cart management, and order processing.
- User authentication (register, login)
- Food item browsing and searching
- Cart management (add, remove, view)
- Order processing
- Responsive design for mobile and desktop
- Node.js
- Express.js
- MongoDB with Mongoose
- JWT for authentication
- Multer for file uploads
- React
- React Router for navigation
- Axios for API requests
- Vite for build tooling
food_del/
├── backend/ # Backend server code
│ ├── config/ # Configuration files
│ ├── controllers/ # Route controllers
│ ├── middleware/ # Custom middleware
│ ├── models/ # Database models
│ ├── routes/ # API routes
│ ├── uploads/ # Uploaded files
│ ├── .env # Environment variables
│ ├── package.json # Backend dependencies
│ └── server.js # Entry point
│
├── frontend/ # Frontend React application
│ ├── public/ # Static files
│ ├── src/ # Source code
│ ├── package.json # Frontend dependencies
│ └── vite.config.js # Vite configuration
│
└── DEPLOYMENT_GUIDE.md # Deployment instructions
- Node.js (v18 or higher)
- npm or yarn
- MongoDB (local or Atlas)
-
Clone the repository:
git clone https://github.com/yourusername/food_del.git cd food_del -
Install backend dependencies:
cd backend npm install -
Install frontend dependencies:
cd ../frontend npm install -
Set up environment variables:
- Create a
.envfile in the backend directory with the following variables:PORT=4000 MONGODB_URI=your_mongodb_connection_string JWT_SECRET=your_jwt_secret NODE_ENV=development
- Create a
-
Start the backend server:
cd backend npm run dev -
Start the frontend development server:
cd frontend npm run dev -
Open your browser and navigate to
http://localhost:5173
For detailed deployment instructions, see DEPLOYMENT_GUIDE.md.
This project is licensed under the ISC License.
- MongoDB Atlas for database hosting
- Render/Vercel/Netlify for deployment options