This is a basic template for a Node.js project using TypeScript + ESLint and Vitest. It provides a basic structure to quickly start developing.
- Node.js (versão >= 18.16.0)
- pnpm (optional, but recommended)
Clone the repository:
git clone https://github.com/bdaseris/node-boilerplate.gitdocker compose up -ddocker compose down(down the containers)docker compose up -d <container_name>(up the specified container)docker compose exec -it app_backend /bin/bash(enter in the container)
Install the dependencies:
pnpm install --frozen-lockfile- To start the development server:
pnpm dev:server - To run the tests:
pnpm test - To generate test coverage:
pnpm test:coverage - To build the production version:
pnpm buildnot necessary on development
pnpm typeorm migration:generate -- -d ./src/persistences/typeorm/datasource.ts
pnpm typeorm migration:run -- -d ./src/persistences/typeorm/datasource.ts
pnpm typeorm migration:revert -- -d ./src/persistences/typeorm/datasource.tsThis project uses the following technologies and tools:
- Node.js
- TypeScript
- ESLint
- Vitest
The ESLint configuration can be found in the .eslintrc.json.
Feel free to contribute to the improvement of this project. Simply open a pull request with your modifications.
This project is licensed under the ISC license. See the LICENSE file for more information.