1
0
Fork 0
 
 
Go to file Use this template
no_name_user_7718 43a99b82dd fix: readme 2023-12-09 14:54:53 +03:00
.scripts Init 2023-12-09 14:50:50 +03:00
server Init 2023-12-09 14:50:50 +03:00
.env.example Init 2023-12-09 14:50:50 +03:00
.eslintignore Init 2023-12-09 14:50:50 +03:00
.eslintrc.js Init 2023-12-09 14:50:50 +03:00
.gitignore Init 2023-12-09 14:50:50 +03:00
.sequelizerc Init 2023-12-09 14:50:50 +03:00
README.md fix: readme 2023-12-09 14:54:53 +03:00
app.js Init 2023-12-09 14:50:50 +03:00
build.json fix: readme 2023-12-09 14:54:53 +03:00
package.json Init 2023-12-09 14:50:50 +03:00

README.md

backend-template (Node.js)

List of contents

Technologies used

Technology name Link
Node.js Website
PostgreSQL Website

List of libraries used

Library name Purpose Link
bluebird for parallel asynchronous operations await Promise.all([]) Website
camelcase for parsing filenames Website
decamelize for parsing filenames Website
dotenv for environment variables Website
express framework of the entire application for the API Website
cors for corses Website
morgan for logging requests Website
log4js for logging requests Website
chalk for logging requests Website
pg to work with the database Website
pg-hstore to work with the database Website
sequelize as an ORM for working with the database Website
sequelize-auto-migrations for automatic creation of migrations from ORM models Website
sequelize-cli for database operations Website
ws to work with the web socket Website
joi for validation Website

How to use

List of contents

Pre commit hook

Copy the .scripts/pre-commit file to the .git/hooks/ folder to automatically fill in the build.json file before the commit.

Run application

  1. Copy .env.example, change its name to .env, and populate the file according to your environment;
  2. Run the command:
npm i

to set dependencies; 3. Run the command:

npm run db:migrate:create
  1. Run the command:
npm run db:seed
  1. Execute the command:
npm run start

to run the application.