Abstract
Readonly
Abstract
closedAbstract
dbAccess to raw database connection object. Use this for close database via yourDbVariable.db.close()
Abstract
deleteAbstract
deleteAbstract
followSet a listener that follow updates happened only with the selected items in store
// Follow one item:
db.followDataUpdates<ItemType, number>('store', 123, callback)
// Follow multiple items, if no keys array - follow all changes in store:
db.followDataUpdates<ItemType, number>('store', [123, 124], callback)
// Explicit follow all changes in store:
db.followDataUpdates<ItemType>('store', { getAll: true }, callback)
Name of database store
Key of item to follow / array of item keys to follow, if no - fallback to all store items / explicit { getAll: true } to follow all changes in store
Async function that calls every time when updates happened with selected items
Abstract
getAbstract
getReceive all items from the store
Name of database store
Optional
onData: DataReceivingCallback<T>Sync function that calls every time when next item received
Abstract
hasCheck for item with key exist or return how much items are in the store if no keys argument
Name of database store
Optional
keys: K | K[]Key value to access item in store, if no key - return items amount in the store
Abstract
onSet a listener to the store that calls every time some changes in the store happened
Name of database store
Async function that calls every time when 'set', 'delete' and 'deleteAll' operations in the store happens
Abstract
setAdd or rewrite item in the store
{title: 'Book', author: 'Bob', data: new ArrayBuffer(32), pages: 12}
Name of database store
Serializable object that IDB can store
Abstract
updateConvenient method for get, modify and set back item to the store
Name of database store
Key value to access item in the store
Async function that receives item and can directly modify them
Generated using TypeDoc
Flag to check is connection to database was closed due to versionchange event