Table of Contents

Importance

Open at App Start

// Example open with indexes, versioning is auto
// one -> single value
// one -> single value and unique
// arr -> array field
// arr_u -> array field and unique
idb.open("sobuuk",{
    store1:[
        "Name",one, "Age",one, ["Name","Age"],one, "Phone",one_u
    ]
});

Reopen and Query

var Db = idb.reopen("mydb");
var Trans = Db.transaction("mystore",RW); // or RO
await idb.insert_one(Trans,{foo:"bar"});
Db.close();