Enables the use of express middleware functions.
{
"use": "express-session",
"options" : {
"secret": "keyboard cat",
"resave": false,
"saveUninitialized": true
}
}
Example of mapping with the
use
handler
Important
Supports only middleware functions accepting exactly three parameters (request
, response
and next
) as described here.
option | type | default | description |
---|---|---|---|
options |
object |
{} |
Options passed to the middleware factory |