express-boilerplate-node v1.0.8
express-boilerplate-node
Fast, unopinionated, minimalist boilerplate Node.js.
├── docker-compose.yml
├── Dockerfile
├── package.json
├── package-lock.json
├── prettier.config.js
├── src
│ ├── app.ts
│ ├── common
│ ├── config
│ ├── connection.ts
│ ├── controllers
│ ├── helpers
│ ├── interfaces
│ ├── models
│ ├── responses
│ ├── server.ts
│ ├── test
│ ├── utils
│ └── validations
├── swagger.json
└── tsconfig.jsonInstallation
This is a Node.js module available through the npm registry.
Before installing, download and install Node.js. Node.js 0.10 or higher is required.
If setting this first time using
npm install command globally:
Installation is done using the
npm install express-boilerplate-node -g command:
$ npm install express-boilerplate-node -gContribute to readMe.
Features
- Easy and efficient code.
- Integrated with husky hooks for pre commit.
- Highly scalable at large stages
- Good test coverage
- MVC structure with environment variables
- 3 database structure with example
- Executable for generating applications quickly
Quick Start
The quickest way to get started with express is to utilize the executable npx express-boilerplate-node to generate a template as shown below:
Install the executable. The executable's major version will match Express's:
$ npm install -g express-boilerplate-nodeCreate the boilerplate:
$ npx express-boilerplate-node [project-name]Select boilerplate
? select the databse you want to use ? (Use arrow keys)
❯ cassendra database
mongoDB database
Mysql databasePlate setup:
$ npm run setStart the docker:
$ docker compose upStart app:
$ npm run devBuild app:
$ npm startView the backend at: http://localhost:${PORT}/api/typec
Philosophy
The main philosophy is to provide small, robust tooling for backend developers, making it a great solution for quick application setup on diverse databses, HTTP APIs.
express-boilerplate-node does not force you to use any specific ORM or template engine. With support for over
Examples
To view the examples, clone the boilerplate repoz and install the dependencies:
cassandra-database
$ git clone https://github.com/coolveer/boilerplate-node-express-cassandra
$ cd boilerplate-node-express-cassandra
$ npm run setmongodb-database
$ git clone https://github.com/coolveer/boilerplate-node-express-mongodb
$ cd boilerplate-node-express-mongodb
$ npm run setcassandra-database
$ git clone hhttps://github.com/coolveer/boilerplate-node-express-mysql
$ cd boilerplate-node-express-mysql
$ npm run setThen run whichever example you want:
$ npm run devContributing
Our project welcomes all constructive contributions. Contributions take many forms, from code for bug fixes and enhancements, to additions and fixes to documentation, additional tests, triaging incoming pull requests and issues, and more!
Feel free to contribute at express-boilerplate-node-github
Running Tests
To run the test , :
$ npm run fix //eslint && prettier && mocha-chai tests
$ npm test //mocha-chai test