Skip to content

adax10/nestjs-template

Repository files navigation

NestJS starter

Installation

$ yarn

Running the app

# development
$ yarn start

# watch mode
$ yarn start:dev

# production mode
$ yarn start:prod

Test

# unit tests
$ yarn test

# test coverage
$ yarn test:cov

Env configuration

NODE_ENV=development|production (optional enum NodeEnv, default development)
# express
API_PORT=3000 (optional number, default 3000)
API_HOST=0.0.0.0 (optional string, default 0.0.0.0)
# cors
CORS_ALLOWED_ORIGING=string (optional string, default *, for eg. http://localhost:3000)
# throttler
THROTTLER_LIMIT=100 (optional number, default 100 - count of request in time window)
THROTTLER_TTL_S=60 (optional number, default 60 - time window)
# body parser
MAX_FILE_SIZE_KB=20971520 (optional number, default 20971520 - 20MB)
# morgan
USE_LOGS=boolean (optional boolean, default true)
# swagger config
USE_SWAGGER=true (optional boolean, default true)
SWAGGER_ROUTE=/swagger (required string, if USE_SWAGGER true)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published