/node-api-template

A collection of (subjective) best (good) practices for creating WebAPIs in node.js

Primary LanguageJavaScriptApache License 2.0Apache-2.0

node-api-template

A (subjective) collection of best (good) practices for creating WebAPIs in node.js

This project is a template where I collect pattern, frameworks and concepts that have proven to work for me in a large number of node.js projects in the past years. It is a subjective collection that reflects my understanding of code quality, maintainability and how to create "good" software in node.js.

When I start a new project, be it private or professional, this template most of the time is the starting point. Often, the template changes after the project due to new lessons learned.

This sample uses node.js in version 4.2.3 LTS with all supported ES6 features.

It works out of the box and provides a sample API for user management.

Key technologies

App

  • express.js
  • Swagger
  • superagent
  • Mongoose

Testing

  • sinon, chai, mocha
  • supertest