MongoDB-like API for HTML5 Storage (localStorage and sessionStorage)

NOTICE: The npm package name is ‘storagedb2

Getting started

Collection Supported methods

Usage

insert

Users.insert({
    id: 100,
    name: 'Elon',
    age: 12
})

Users.insert([{
    id: 101,
    name: 'Larry',
    age: 21
}, {
    id: 102,
    name: 'Sergey',
    age: 21
}])Copy the code

find

Users.findOne(102)

Users.findOne({
    age: {
        $ne: 21}})Copy the code

remove

Users.remove(101)

Users.remove({
    age: 21
})Copy the code

License

MIT