middleware docs

This commit is contained in:
Lloyd Brookes
2016-07-18 17:33:07 +01:00
parent 9d3484fed6
commit a9af4fa959
2 changed files with 14 additions and 1 deletions

View File

@ -246,7 +246,6 @@ function loadModule (modulePath) {
return module
}
function getIPList () {
const flatten = require('reduce-flatten')
const os = require('os')

14
lib/middleware.js Normal file
View File

@ -0,0 +1,14 @@
'use strict'
class Middleware {
/**
* Return one or more options definitions to collect command-line input
* @returns {OptionDefinition|OptionDefinition[]}
*/
optionDefinitions () {}
/**
* Return one of more middleware functions with three args (req, res and next). Can be created by express, Koa or hand-rolled.
*/
middleware (localWebServer) {}
}