Skip to content
This repository has been archived by the owner on Feb 6, 2023. It is now read-only.

otaviotscha/nodejs-api-boilerplate

Repository files navigation

NodeJS API Boilerplate

Requirements

To run this project you will need:

  1. NodeJS
  2. Yarn

Environment

  • .env file is read when in production.
  • .env.dev file is read when calling yarn dev (development environment).
  • .env.test file is read when calling yarn test (test environment).

You can use .env.sample to know how to configure the .env to your needs.

.env.sample also contains the environment defaults.

Scripts

  • yarn prisma migrate dev to generate/sync database accordingly to migrations (or generate migration if schema.prisma was modified).
  • yarn dev to run app in development environment.
  • yarn test to run tests.
  • yarn prod to build TypeScript to JavaScript then run app in production environment simulation.

API Documentation

Main packages