simple offline storage
Offline storage for key/value with an async api and optional key prefixing.
var kayv = ;var db = ;// set a valuedb;
Similar to localStorage API except a callback
fn is called when operations are complete. Callback functions follow "error first" style with the first argument being an
Error instance or
null if success.
Return a new
Db instance to access key/values. The
prefix is used to namespace all of the keys in this way allowing you to create separate "dbs".
Clear all values from the db.
Get the value for a given
key. If there is no
value will be
null. Lack of value is NOT an error.
value for a given
key. Value can be any JSON serializable type.
Remove a given
key from the db.
Return the number of total keys.
Get the key at