Great deals on laptops!
- React + Vite: Frontend
- NestJS: Backend
- Turborepo: bundler and build system
- Postgres
- Prisma: ORM
- Docker
- pnpm: package manager
This repo contains a frontend and a backend app. The frontend source code lives in apps/store
and the backend source code lives in apps/api
.
Run the following commands from the root of the repo. No need to change directories into each app.
Install project dependencies
pnpm install
Generate prisma client
pnpm --filter api prisma:generate
Start database
docker compose up -d
Run migrations
pnpm run --filter api prisma:migrate
Create .env
file for api
cp apps/api/.env.example apps/api/.env
Important
Update the DATABASE_URL
environment variable if not using provided docker database
Seed the database
pnpm run --filter api seed
Start frontend and backend dev servers
pnpm run dev
Both apps should now be running and viewable:
- Frontend: http://localhost:5173
- Backend: http://localhost:3000