Skip to content

hantsy/nestjs-rest-sample

Repository files navigation

NestJS Sample

Build Dockerize e2e codecov

A sample NestJS project demonstrating RESTful APIs.

Features include:

  • APIs that meet Richardson Maturity Model Level 2
  • A custom Mongoose integration module (instead of @nestjs/mongoose)
  • Passport/JWT authentication using simple text secrets
  • Comprehensive tests built with Jest, jest-mock-extended, ts-mockito, @golevelup/ts-jest, etc.
  • GitHub Actions workflows for continuous testing, coverage reporting, Docker image builds, and more

Documentation

Build & Run

Make sure you have Node.js and npm installed, then run the following commands in the project directory to install dependencies:

npm install

Start the application:

# development
npm run start

# watch mode
npm run start:dev

# production
npm run start:prod

Run tests:

# unit tests
npm run test

# end-to-end tests
npm run test:e2e

# coverage report
npm run test:cov

References

Helpful courses from wanago.io:

Releases

No releases published

Packages

 
 
 

Contributors