/nestjs-typeorm-starter

NestJS + TypeORM + PostgreSQL Starter

Primary LanguageTypeScriptMIT LicenseMIT

Nest Logo

A progressive Node.js framework for building efficient and scalable server-side applications, heavily inspired by Angular.

NPM Version Package License NPM Downloads Travis Linux Coverage Discord

Description

Nest framework TypeScript starter repository.

Main differences of nestjs/typescript-starter:

Other features:

  • Wallaby JS works out of the box without any additional config
    Notice: How to run in "Without Configuration" mode (Official Wallaby JS Guide)

Ways to use

  1. Clone as is

    1. git clone git@github.com:korniychuk/nestjs-starter.git
    2. cd nestjs-starter
    3. yarn
  2. Fork

    1. Click Fork git button
    2. git clone git@github.com:YOUR_GIT_NAME/nestjs-starter.git
    3. cd nestjs-starter
    4. yarn
  3. Creating from template

    1. Click Fork git button
    2. Create new repository and specify template template
    3. git clone git@github.com:YOUR_GIT_NAME/NEW_REPOSITORY_NAME.git
    4. cd NEW_REPOSITORY_NAME
    5. yarn
  4. Using with already cloned repository as an additional origin for pulling updates

    1. Automatically

      npm run merge-tpl-repo
    2. Manually

      1. git remote add template git@github.com:korniychuk/nestjs-starter.git
      2. git fetch template
      3. git merge --allow-unrelated-histories template/master

How to

How to use NodeJS version from the .nvmrc

  1. Install NVM

  2. Use .nvmrc file one of the next ways:

    • Execute nvm use in the project root directory
    • Install NVM Loader and your .nvmrc will be loaded automatically when you open the terminal. NVM Loader demo

Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# debug mode
$ npm run start:debug

# production mode
$ npm run build:prod
$ npm run start:prod

Test

# unit tests
$ npm run test

# watch mode
$ npm run test:watch

# specific tests
npm run test -- src/my.spec.ts
npm run test:watch -- src/my.spec.ts

# e2e tests
$ npm run test:e2e

# test coverage
$ npm run test:cov

Lint

# Just show problems
$ npm run lint

# Fix problems if it is possible
$ npm run lint:fix

Author


Anton Korniychuk