Built following a YouTube tutorial by EdRoh.
- Install MongoDB onto your computer: Installation Instructions
- Add a .env file to the
server
directory. Inside add:
MONGO_URL = <url-to-your-mongo-db>
PORT=5001
- Install all the dependencies using:
npm i
- Uncomment the part in
server/index.js
that talks about importing data. After the first run of the server, make sure to re-comment this.
MERN-admin-dashboard/server/index.js
Lines 57 to 62 in cd69579
- Move into your client directory and install all of their dependencies:
npm i
- Add a .env.local file to the
client
directory. Inside add:
REACT_APP_BASE_URL=http://localhost:5001
- Open up two terminals and run these commands:
cd server
npm run dev
cd client
npm run start
- This should automatically open react, it may take a while to load...