single-session-middleware

1.0.0 • Public • Published

single-session-middleware

Keep a single and latest session in the server end.

Installation

$ npm i single-session-middleware -D

Node.js

import express from 'express'
import singleSession from 'single-session-middleware'
import proxy from 'http-proxy-middleware'
 
const app = express()
 
app.use(singleSession({
  name: 'PHPSESSID'
}))
 
app.use(proxy({
  target: 'http://192.168.1.1',
  changeOrigin: true
}))
 
app.listen(3000)

Options

  • options.name: string, the cookie-name that some programming languages. Default: connect.sid.

References

License

MIT

/single-session-middleware/

    Package Sidebar

    Install

    npm i single-session-middleware

    Weekly Downloads

    1

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    2.81 kB

    Total Files

    5

    Last publish

    Collaborators

    • zuojiang