A progressive Node.js framework for building efficient and scalable server-side applications.
Nest framework TypeScript starter repository.
$ make start
$ npm install
# development
$ npm run start
# watch mode
$ npm run start:dev
# production mode
$ npm run start:prod
The fake database comes with 5 accounts with the same password: yoyo
# unit tests
$ npm run test
# e2e tests
$ npm run test:e2e
# test coverage
$ npm run test:cov
the database can be seen at http://localhost:8080/ (user: root, password: yoyo)
When updating an Entity, TypeORM will not update the database automatically, as it is unsafe to do so. We work with migrations.
for TypeORM to be aware of Entity changes, run:
$ npm run typeorm migration:generate src/migration/whateverTitleYouWant
This command will create a file with the queries necessary to synchronize the database with your Entity.
Once this file is created, run:
$ npm run typeorm migration:run
This will run the queries inside the src/migration/whateverTitleYouWant
file
and you're done!
learn more about migrations here