e-commerce site run by MERN stack
Create a .env file in then root and add the following
NODE_ENV = development
PORT = 5000
MONGO_URI = your mongodb uri
JWT_SECRET = your JWT secret
MAILGUN_KEY = your mailgun key
MAILGUN_DOMAIN = your mailgun domain
MAILGUN_EMAIL_SENDER = [email protected](your mailgun sender)
GOOGLE_CLIENT_ID=your google client id
GOOGLE_CLIENT_SECRET=your google client secret
GOOGLE_CALLBACK_URL=your google callback url
BASE_SERVER_URL=your base server url
npm install
cd frontend
npm install
# Run frontend (:3000) & backend (:5000)
npm run dev
# Run backend only
npm run server
# Run frontend only
npm run client
You can use the following commands to seed the database with some sample users and products as well as destroy all data
npm run data:import
npm run data:destroy