This project was made to simulate on how vending machine works. The backend is the API for the vending machinesee endpoint docs here, allowing users with a “seller” role to add, update or remove products, while users with a “buyer” role can deposit coins into the machine and make purchases.. Frontend is made with React (JavaScript) and backend is made using Nodejs, Express and MongoDB.
See Live demo here.
- Change directory to backend and install required packages:
cd backend npm install
-
There is config folder with configuration. Be sure to change them according to your running environment.
-
Now you can run you application. To run it in dev mode:
npm run dev
-
To run the backend test:
npm run test
-
If everything goes well the backend is running port at 3005, you can visit your application through http://localhost:3005
- Change directory to frontend application:
cd frontend
- Install dependencies
npm install
- Run your application:
npm start