1.0.4 • Published 7 years ago

express-route-creator v1.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
7 years ago

express-route-creator

Custom route creator with middleware for express.

Installation NPM

npm install express-route-creator

Installation GitHub

Clone the repository and install the dependencies

npm install 

Follow the start instructions to continue

Usage

import

initialize MiddlewareCreator() and RouteCreator(expressApp, middlewareObj)

setMiddleware(function)

Set middleware for express route group.

Example:

Example multiple middleware functions:

create(route, function)

Create the router

  • route define the route, use G/ for a GET route and P/ for a POST route
  • function provide a function for the route

Example:

Start

Run example:

npm start
1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago