This monorepo contains both the frontend and backend applications for GrubDash, a food delivery platform that allows users to browse restaurants, view menus, and place orders.
- Browse restaurant menus and dishes
- Create, read, update, and delete dishes
- Place and manage food orders
- Real-time order status tracking
- Responsive design for mobile and desktop
- React.js
- React Router for navigation
- CSS for styling
- Jest for testing
- Express.js
- RESTful API architecture
- Jest for testing
- JSON for data storage
.
├── frontend/ # React frontend application
└── backend/ # Express.js backend API
- Node.js (v14 or higher)
- npm (v6 or higher)
- Clone this repository
- Install all dependencies for frontend, backend, and root project:
npm run install:all
To run both frontend and backend in development mode:
npm run start:dev
This will concurrently start:
- Frontend on http://localhost:3000
- Backend on http://localhost:5000
Frontend only:
npm run start:dev:frontend
Backend only:
npm run start:dev:backend
The backend provides the following RESTful endpoints:
- GET /dishes - List all dishes
- POST /dishes - Create a new dish
- GET /dishes/:dishId - Get a specific dish
- PUT /dishes/:dishId - Update a dish
- GET /orders - List all orders
- POST /orders - Create a new order
- GET /orders/:orderId - Get a specific order
- PUT /orders/:orderId - Update an order status
Run all tests:
npm test
Test frontend only:
npm run test:frontend
Test backend only:
npm run test:backend
To create a production build of the frontend application:
npm run build
API_BASE_URL
: Base URL for the API (defaults to http://localhost:5000 if not set)
PORT
: Port number for the server (defaults to 5000)
npm run start:dev
- Start both frontend and backend in development modenpm run start:dev:frontend
- Start frontend onlynpm run start:dev:backend
- Start backend onlynpm run install:all
- Install dependencies for all applicationsnpm run instal 5F35 l:frontend
- Install frontend dependenciesnpm run install:backend
- Install backend dependenciesnpm test
- Run all testsnpm run test:frontend
- Run frontend testsnpm run test:backend
- Run backend testsnpm run build
- Create production build of frontend
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Open a Pull Request
ISC