local-store
A localStorage based store with namespacing
Example
var store = require("local-store")
, assert = require("assert")
store.set("foo", "bar")
assert.equal(store.get("foo"), "bar")
// cleanup
store.delete("foo")
Example name spaced
var createStore = require("local-store").createStore
, store = createStore("my-unique-namespace")
store.set("foo", {
json: "works too"
})
assert.deepEqual(store.get("foo"), {
json: "works too"
})
Installation
npm install local-store
Tests
make test
Contributors
- Raynos