Skip to content
This repository has been archived by the owner on Aug 14, 2022. It is now read-only.

peciulevicius/eds-store

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

e-Commerce MERN stack application


Env Variables

PORT note: if you're using an apple device, you might want to use PORT = 4000, since Apple uses PORT 5000 for Apple Airplay receiver by default

Create a .env file in the root directory and add the following:

NODE_ENV = development
PORT = 5000
MONGO_URI = your mongodb uri
JWT_SECRET = 'abc123'
PAYPAL_CLIENT_ID = your paypal client id

Installation

Install needed dependencies for frontend and backend:

npm install
cd frontend
npm install

Running development server

PORT note: you might want to change this backend port on Apple devices as well


# Run frontend (:3000) & backend (:5000)
npm run dev

# Run backend only
npm run server

Production building and deploying

# Create frontend production build
cd frontend
npm run build

How to run tests?

To run tests, clone the project and install the dependencies. Now to run the tests we want to go into the frontend directory of the project and run the command: npm run test or npm run test:coverage to run our testing coverage.*

*The app is not fully tested, so if you would like to test this application and contribute, just fork the project, make your changes and open a pull request :)