🗄️ Nest.js + TypeORM with a Custom Repository
An example of how to use a custom repository of TypeORM within Nest.js
🚨 NOTICE 🚨 this example now works with TypeORM v0.3.x for previous version check out v1.0.0
Features
- TypeORM with custom repository
- Unit tests and E2E tests
- Check code quality with MegaLinter
- Run tests with github actions
Run Locally
Clone the project
git clone https://github.com/leosuncin/nest-typeorm-custom-repository.git
Go to the project directory
cd nest-typeorm-custom-repository
Install dependencies
yarn install
Start the server
yarn start:dev
Running Tests
To run unit tests, run the following command:
pnpm test
To run e2e tests (the MySQL instance must be available), run the following command:
pnpm test:e2e
Tech Stack
Server: Typescript, SQLite, Nest.js, TypeORM
Test: Jest, SuperTest
Author
👤 Jaime Leonardo Suncin Cruz
- Twitter: @jl_suncin
- Github: @leosuncin
- LinkedIn: @jaimesuncin
Show your support
Give a ⭐️ if this project helped you!
Related
Here are some more example projects with Nest.js
License
Release under the terms of MIT