cookie session middleware for connect
JavaScript
Switch branches/tags
Pull request Compare This branch is 4 commits ahead, 27 commits behind defunctzombie:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
test
.gitignore
.travis.yml
README.md
index.js
package.json

README.md

yummy Build Status

Yummy is cookie session middleware for connect and its derivatives.

why?

Cause you already have to use a cookie for sessions so why do more IO to get the data.

how?

npm install yummy

Just drop the yummy middleware into your middleware stack after the cookie parser

var yummy = require('yummy');

app.use(connect.cookieParser());
app.use(yummy({
    secret: 'fizzbuzz'
});

tell me more

You can configure yummy with the following options.

secret [required]

the cookie will be encrypted using this secret string, keep it safe :)

cookie [optional]

the cookie options sets the default value for session cookies. You can

maxAge

the max age of the cookie in milliseconds

path

the path of the session cookie (default is '/')