JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 642
  • Score
    100M100P100Q99338F
  • License MIT

A node.js module to run connect-like middlewares in sequence

Package Exports

  • connect-sequence

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (connect-sequence) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

connect-sequence

GitHub tag npm Bower

JavaScript Style Guide Semver 2.0 Gitter

A node.js module to run connect-like middlewares in sequence

What is connect-sequence

This module is intended to be used in a connect or express application.

In an express application, you manipulate middlewares. The request walkthru the middlewares you registred in the same order you registred it.

This is super cool but sometimes, we would want to register the middleware sequence dynamically, i.e. at runtime.

connect-sequence aims to make a such thing super-easy!

Usage

/**
 * Product API
 * @module
 */

var conSeq = require('connect-sequence')
var productsController = require('./products.controller')

module.exports = productRouter

function productRouter (app) {
  app.route('/api/products/:productId').get(function (req, res, next) {

  })
}


Installation

With node package manager (recommanded)

npm install --save connect-sequence

Or manually

Download:

wget https://github.com/sirap-group/connect-sequence/archive/v1.0.0.zip

Extract:

unzip v1.0.0.zip

Move in the node_modules directory:

mv connect-sequence ./node_modules/connect-sequence

Credits

Copyright © 2016 SIRAP Group, All Rights Reserved

License

This project is licensed under the MIT license