express-session-better-sqlite3
v1.2.1
Published
SQLite session store for ExpressJS session middleware / express-session using better-sqlite3
Downloads
57
Readme
express-session-better-sqlite3
SQLite session store for ExpressJS session middleware / express-session using better-sqlite3.
Usage
const betterSqlite3 = require('better-sqlite3');
const expressSession = require('express-session');
const expressSessionBetterSqlite3 = require('express-session-better-sqlite3');
const sqliteDb = new betterSqlite3(dbFilePath, dbOptions);
const BetterSqlite3SessionStore = expressSessionBetterSqlite3(expressSession, sqliteDb);
const app = express();
app.use(expressSession({
store: new BetterSqlite3SessionStore(),
...
}));