A progressive Node.js framework for building efficient and scalable server-side applications.
Nest framework TypeScript starter repository.
Friendly errors on response
- Custom validators
- Unique constraint
- Exist constraint
- All errors are returned inside "errors" key on response.
- Validate model data before saving to database to get all database errors (via custom validators)
$ npm install
$ cp .env.example .env
# migrate database
$ npm run migration:run
# development
$ npm run start
# watch mode
$ npm run start:dev
# production mode
$ npm run start:prod
- change
DB_HOST
in .env toDB_HOST=postgres
- run:
# run docker in background
$ docker-compose up -d
# run migrations
$ docker-compose exec dev npm run migration:run
- Run tests with docker
# up postgres service
$ docker-compose up postgres
# run unit tests
$ docker-compose exec dev npm run test
# run e2e tests
$ docker-compose exec dev npm run test:e2e
# migrate database
$ npm run migration:run
# revert last migration
$ npm run migration:revert
# generate migration
$ npm run migration:generate
# unit tests
$ npm run test
# e2e tests
$ npm run test:e2e
# test coverage
$ npm run test:cov
- TypeORM
- Migrations
- CRUD User
- CRUD Notification
- JWT
- Access Token
- Refresh Token
- Pagination
- Unit tests
- Use cases
- Controllers
- Coverage 100% (30%)
- e2e tests
- Coverage 100% (96% is almost 100% 👌)
- Database constraints
- Fix docker
- Update README.md with docker steps
- Run tests on Pull Requests
- PR template
Nest is an MIT-licensed open source project. It can grow thanks to the sponsors and support by the amazing backers. If you'd like to join them, please read more here.
- Author - Kamil Myśliwiec
- Website - https://nestjs.com
- Twitter - @nestframework
Nest is MIT licensed.