Skip to content

Latest commit

 

History

History
15 lines (11 loc) · 424 Bytes

File metadata and controls

15 lines (11 loc) · 424 Bytes

localStorage API for Node.js

Follows webstorage specification: http://www.w3.org/TR/webstorage/. Will write to persistent storage upon Node process exit.

Usage

var Storage = require('localStorage').Storage;
var localStorage = new Storage("localStorage.dat");
localStorage.foo = "bar";
localStorage.setItem("abc", "xyz");

For just in-memory storage, call the Storage constructor without a filename.