0.2.0 • Published 8 years ago

generator-restify v0.2.0

Weekly downloads
2
License
MIT
Repository
github
Last release
8 years ago

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.

Installation

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

License

MIT

0.2.0

8 years ago

0.1.2

8 years ago

0.1.1

9 years ago

0.1.0

9 years ago