Skip to content

ashishkk22/pizza-app-mern-microfrontend-ts

Repository files navigation

Pizza Delivery Web App (Micro-Frontend) - MERN

Demo Link

Signup Page

Screenshot from 2023-06-05 12-14-02

Home Page

Screenshot from 2023-06-05 12-14-34

Admin Panel

image


👾 Tech Stack

Client
Server
Database

Nx Graph

graph (1)

🎯 Features

  • Basic signup and login functionalities with email OTP-based authentication.
  • An admin panel allows administrators to manage coupons, products, and categories.
  • Admins can accept orders and update their status.
  • Image uploads are supported using ImageKit.
  • Users can view their order history, receive live updates, and manage multiple addresse

📁 Project Structure

The project is using nx monorepo.

  • apps: contains micro frontend apps with its host.
  • lib: contains shared UI , react query client and redux store between micro fontend apps.

image

🔑 Environment Variables

To run this project, you will need to add the following environment variables to your .env file. you can refer .env.example file for the references.

Variables NX_PORT_API NX_MONGODB_URL NX_IMAGE_KIT_URL NX_IMAGE_KIT_PUBLIC_KEY NX_IMAGE_KIT_PRIVATE_KEY NX_EXPIRE_OTP NX_GMAIL_PASS NX_GMAIL_USER NX_JWT_COOKIE_EXPIRES NX_JWT_EXPIRE NX_JWT_SECRET NX_CLIENT_HOST NX_CLIENT_ADMIN

🧰 Getting Started

System Requirements

  • git v2.13 or greater
  • nodejs 14 || 16 || 18
  • npm v8.16.0 or greater

All of these must be available in your PATH. To verify things are set up properly, you can run this:

git --version
node --version
npm --version

‼️ Prerequisites

This project uses pnpm as package manager

 npm install --global pnpm

🏃 Run Locally

Clone the project

  https://github.com/ashishkk22/pizza-app-mern-microfrontend-ts.git

Go to the project directory

  cd pizza-app-mern-microfrontend

Install dependencies and add the required environment variables in the .env (reference .env.example)

  pnpm install

To start the host app in development run.

  pnpm nx serve host --devRemotes="cart,shop,auth"

To start the admin app in development run.

  pnpm nx serve admin --devRemotes="auth"

To start the server in development run

  nx serve api

🤝 Contact

Ashish Kachhadiya - [email protected]