https://github.com/smrchy/fp-lua-sessions
https://github.com/smrchy/fp-lua-sessions
Last synced: 5 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/smrchy/fp-lua-sessions
- Owner: smrchy
- License: mit
- Created: 2021-05-18T10:22:42.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2021-06-17T13:29:40.000Z (over 4 years ago)
- Last Synced: 2025-05-01T08:13:47.462Z (5 months ago)
- Language: TypeScript
- Size: 13.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# FP LUA Sessions
Creates a `res.locals.session` object or calls next(err) if no session is there.
Usage:
```
import { resolveSession } from "fp-lua-sessions";app.get("/some_endpoint", resolveSession, (req, res, next) => {
console.log(res.locals.session)
res.send("OK")
}
```or
```
import { resolveSession } from "fp-lua-sessions";app.use(resolveSession);
```