https://github.com/henriqueweiand/nestjs-ecommerce
Example to exercise clean architecture with different databases + cache layer + DDD
https://github.com/henriqueweiand/nestjs-ecommerce
cache clean-architecture ddd e2e-tests github-actions jest mongodb mongoose nestjs postgresql prisma unit-testing
Last synced: 3 months ago
JSON representation
Example to exercise clean architecture with different databases + cache layer + DDD
- Host: GitHub
- URL: https://github.com/henriqueweiand/nestjs-ecommerce
- Owner: henriqueweiand
- Created: 2024-02-22T22:14:18.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2024-03-20T21:56:23.000Z (over 1 year ago)
- Last Synced: 2025-03-24T08:07:42.878Z (3 months ago)
- Topics: cache, clean-architecture, ddd, e2e-tests, github-actions, jest, mongodb, mongoose, nestjs, postgresql, prisma, unit-testing
- Language: TypeScript
- Homepage:
- Size: 475 KB
- Stars: 33
- Watchers: 2
- Forks: 10
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# NestJS e-commerce
Example to exercise clean architecture with different databases + cache layer + DDD.
[](https://github.com/henriqueweiand/nestjs-ecommerce/actions/workflows/run-e2e-tests.yml)
[](https://github.com/henriqueweiand/nestjs-ecommerce/actions/workflows/run-unit-tests.yml)blog post about the project -> https://medium.com/nestjs-ninja/mastering-nestjs-unleashing-the-power-of-clean-architecture-and-ddd-in-e-commerce-development-97850131fd87
## Pre requirements
- To use the full project, you will need to have a Stripe dev account;
- Mongo or Postgres dabatase;## Running locally
1. Instal the dependecies
2. copy .env.example to .env'
3. run `docker-compose up -d`, it will create a Mongo instance
4. run `yarn start:dev`
5. Access `http://localhost:3000/api`The default database is set Mongo, but it can be changed inside `app.module.ts`
## API Documentation
Running the solution, access `http://localhost:3000/api`

## To-do
- [x] Product
- [x] User
- [x] Order
- [x] Add Mongo
- [x] Add Postgres
- [x] Add way to switch database easly
- [x] Cache layer
- [x] A few Unit tests
- [x] A few e2e tests
- [x] Stripe integration