Skip to content

Instantly share code, notes, and snippets.

@MACSkeptic
Created January 10, 2013 01:23
Show Gist options
  • Save MACSkeptic/4498607 to your computer and use it in GitHub Desktop.
Save MACSkeptic/4498607 to your computer and use it in GitHub Desktop.
app.use(express.static(path.join(__dirname, 'public')));
app.use(express.cookieParser());
app.use(express.session({cookie: {path: '/', maxAge: null}, secret: 'fluffy unicorn'}));
app.use(app.router);
exports.myRoute = function (req, res) {
req.session.identification_token = 'token';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment