Create a restify based RESTful API, with a linter (jshint or jslint)
Latest commit cef336f May 18, 2016 @chris-l Fix travis
Failed to load latest commit information.
app Fix lint errors May 18, 2016
test Fix travis May 18, 2016
.editorconfig First commit Apr 27, 2015
.gitignore First commit Apr 27, 2015
.travis.yml Fix travis May 18, 2016 Updated readme and version bump May 18, 2016
package.json Updated readme and version bump May 18, 2016

generator-restify Build Status

A yeoman generator that will create the boilerplate for creating a restify based RESTful API.

It uses npm scripts as the task runner. It also allows to choose between jslint or jshint.

About the folder structure

One of the most relevant parts of this generator is the auto-inclusion of files.

To create a new route, is only necessary to create a file in the routes/ directory that looks like this:

module.exports = function (server) {
  server.get('/info/:param', function (req, res, next) {

  server.put('/info/', function (req, res, next) {

Just for being in the routes directory, the file will be automatically included. Is not necessary to do any other step.


Install: npm install -g generator-restify

Create a new directory and enter inside of it:

mkdir some-app && cd some-app

Run the generator:

yo restify