Hi! I'm Azwar Akbar. Here is the test result for my assessment for Fullstack Dev position. This project was built using Typescript ExpressJS, TypeORM, NextJS, ReactJS.
There are frontend and backend folder project. Enter to the each directory using cd frontend or cd backend
- Enter to backend directory:
cd backend
- Create
.env
file. Just copy paste from file.env.example
- Complete the fields to match yout environtment configuration:
PORT=3001
POSTGRESQLDB_HOST=localhost
POSTGRESQLDB_USER=
POSTGRESQLDB_ROOT_PASSWORD=
POSTGRESQLDB_DATABASE=ecommerce_db
POSTGRESQLDB_LOCAL_PORT=5432
POSTGRESQLDB_DOCKER_PORT=5432
NODE_LOCAL_PORT=80
NODE_DOCKER_PORT=3001
Just skip the DOCKER
related variable. Make sure you have set the variable environtment corectly.
5. Install dependencies: npm install
6. Run database seed: npm run seed
It will create intial data seed for Product and User.
7. Run the project using dev mode: npm run dev
8. Hit the API via URL: http://localhost:3001
9. Check or run each funtion by reffering this Postman API Documentation: https://documenter.getpostman.com/view/1210810/2sA35D64Hc
10. Done
- Enter to backend directory:
cd frontend
- Create
.env
file. Just copy paste from file.env.example
- Complete the fields to match yout environtment configuration: Make the frontend to point to our Backend API using this variable
NEXT_PUBLIC_API_URL=http://localhost:3001
- Install dependencies:
npm install
- Run project:
npm run dev
- Hit the Frontend via URL: http://localhost:3000
- Done