This repository has been archived on 2026-01-31. You can view files and clone it. You cannot open issues or pull requests or push a commit.
dependabot[bot] 5b81abb04c build(deps): bump cross-spawn in the npm_and_yarn group (#11)
Bumps the npm_and_yarn group with 1 update: [cross-spawn](https://github.com/moxystudio/node-cross-spawn).


Updates `cross-spawn` from 7.0.3 to 7.0.6
- [Changelog](https://github.com/moxystudio/node-cross-spawn/blob/master/CHANGELOG.md)
- [Commits](https://github.com/moxystudio/node-cross-spawn/compare/v7.0.3...v7.0.6)

---
updated-dependencies:
- dependency-name: cross-spawn
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-12-21 18:52:09 +01:00
2024-07-20 18:23:54 +02:00
2024-09-12 12:41:55 +02:00
2023-08-30 20:53:42 +02:00
2024-07-20 18:21:17 +02:00
2023-08-30 20:53:42 +02:00
2024-07-20 18:21:17 +02:00
2023-08-05 17:23:34 +02:00
2023-08-05 17:23:34 +02:00
2023-07-18 21:38:48 +02:00
2024-09-12 12:41:55 +02:00
2023-12-08 21:17:26 +01:00

This is a template for a Node project with TypeScript

It contains basic configurations for the following:

  • TypeScript (typechecking and building)
  • Eslint (linting)
  • Prettier (formatting)
  • Jest/Supertest (testing)
  • Husky (pre-commit hooks to run linting, typechecking, and commit message format)
  • Winston (logging)
  • GitHub Actions (CI/CD)

To do

Add Swagger?

Environment Variables

Need to export the following environment variables:

  • PORT - The port to run the server on (defaults to 3000)
  • DATABASE_URL - The URL to the database, formatted as postgres://<username>:<password>@<host>:<port>/<database>

Commands

Install dependencies:

yarn

Generate Prisma client:

yarn db:generate

Run the migrations:

yarn db:migrate

Reset the database:

yarn db:reset

Audit:

yarn audit

Lint:

yarn lint

Typecheck:

yarn typecheck

Format:

yarn format

Husky hooks:

yarn prepare

Test:

yarn test

Run in development mode:

yarn dev

Build:

yarn build

Run:

node build/index.js

To commit a WIP skipping checks:

git commit -m "WIP: <message>" --no-verify

To run it using Docker, running the server on port 3000:

docker-compose up --build

Description
Template for NodeJS APIs with TypeScript, with configurations for linting and testing
Readme MIT 972 KiB
Languages
TypeScript 92.2%
Dockerfile 7.8%