You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

3.5 KiB

API Reference

LocalWebServer ⇐ module:middleware-stack

Kind: Exported class
Extends: module:middleware-stack

new LocalWebServer([options])

Params

  • [options] object - Server options
    • .port} number - Port
    • .stack} Array.<string> | Array.<Features> - Port

localWebServer.features : Array.<Feature>

Loaded feature modules

Kind: instance property of LocalWebServer

localWebServer.options : object

Config

Kind: instance property of LocalWebServer

localWebServer.view : View

Current view.

Kind: instance property of LocalWebServer

localWebServer.server : Server

Node.js server

Kind: instance property of LocalWebServer

localWebServer.getApplication() ⇒ function

Returns a middleware application suitable for passing to http.createServer. The application is a function with three args (req, res and next) which can be created by express, Koa or hand-rolled.

Kind: instance method of LocalWebServer

localWebServer.getServer() ⇒ Server

Returns a listening server which processes requests using the middleware supplied.

Kind: instance method of LocalWebServer

LocalWebServer~loadStack() ⇒ object

Loads a module by either path or name.

Kind: inner method of LocalWebServer