docs
This commit is contained in:
@ -18,7 +18,7 @@ module.exports = {
|
||||
},
|
||||
{
|
||||
name: 'no-cache', alias: 'n', type: Boolean,
|
||||
description: 'Disable etag-based caching.', group: 'server'
|
||||
description: 'Disable etag-based caching - forces loading from disk each request.', group: 'server'
|
||||
},
|
||||
{
|
||||
name: 'help', alias: 'h', type: Boolean,
|
||||
|
@ -21,9 +21,18 @@ const send = require('koa-send')
|
||||
/**
|
||||
* @module local-web-server
|
||||
*/
|
||||
module.exports = getApp
|
||||
module.exports = localWebServer
|
||||
|
||||
function getApp (options) {
|
||||
/**
|
||||
* Returns a Koa application
|
||||
*
|
||||
* @param [options] {object} - options
|
||||
* @param [options.blacklist] {regexp[]} - a list of forbidden routes.
|
||||
* @alias module:local-web-server
|
||||
* @example
|
||||
* const localWebServer = require('local-web-server')
|
||||
*/
|
||||
function localWebServer (options) {
|
||||
options = Object.assign({
|
||||
static: {},
|
||||
serveIndex: {},
|
||||
|
Reference in New Issue
Block a user