This is a food ordering web application built with the MERN (MongoDB, Express.js, React.js, Node.js) stack. Users can browse menus, add food items to their cart, and make secure payments.
- User Authentication: Users can sign up and log in to access their accounts.
- Menu Browsing: Browse a variety of food items with descriptions and prices.
- Cart Functionality: Add, update, or remove items from the cart.
- Order Placement: Place orders seamlessly with a clean and intuitive UI.
- Payment Gateway Integration: Secure payments for orders.
- Order History: View previously placed orders.
- React.js: For building the user interface.
- React Router: For navigation.
- Node.js: For server-side logic.
- Express.js: For handling routes and API endpoints.
- MongoDB: For storing user data, menu items, orders, and payment details.
- Stripe: For secure payment processing.
- Clone the repository:
git clone https://github.com/BhoomiAgrawal12/food-delivery.git cd food-delivery
- Install dependencies for the frontend and backend:
# Backend cd backend npm install # Frontend cd ../frontend npm install
- Create a
.env
file in the backend directory and configure the following environment variables:PORT=3000 MONGO_URI=your-mongodb-connection-string JWT_SECRET=your-jwt-secret STRIPE_SECRET_KEY=your-stripe-secret-key
- Start the development servers:
# Backend cd backend npm start # Frontend cd ../frontend npm start
- Open your browser and navigate to
http://localhost:3000
to view the application.
root/
├── backend/
│ ├── models/ # Mongoose models
│ ├── routes/ # Express API routes
│ ├── controllers/ # Business logic
│ └── server.js # Entry point
├── frontend/
├── src/
│ ├── components/ # React components
│ ├── pages/ # Page components
│ └── App.js # Main application entry point
We welcome contributions to make this project better! Please follow these guidelines:
- Fork the Repository: Start by forking the repository and creating a local clone.
- Set Up the Project Locally: Follow the installation steps to set up the project on your machine.
- Work on Issues: Check the issues section for tasks or report a new one.
- Create a Branch: Create a feature branch for your changes.
git checkout -b feature/your-feature-name
- Test Your Changes: Ensure your changes work as expected.
- Submit a Pull Request:
- Push your changes to your forked repository.
- Open a pull request with a detailed description of your changes.
- Review and Feedback: Collaborate to review and improve your contribution.
See the CONTRIBUTION file for more details.
This project is licensed under the MIT License.
If you have any questions or suggestions, feel free to reach out:
- Email: [email protected]
- GitHub: Your GitHub Profile