0.1.0 • Published 5 years ago

multipronged v0.1.0

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

multipronged

A wrapper for connect which allows array arguments for use.

Installation

npm install --save multipronged

API

Behaves like connect except that an array of functions can be provided for the use method rather than just a single function.

const app = require('multipronged');

// Without a route:
app.use([middleware1, middleware2, ...etc]);

// Or, with a route:
app.use('route1', [middleware1, middleware2, ...etc]);

// The non-array signatures are also still available:
app.use(middleware);
app.use('route2', otherMiddleware);