johanneslumpe / idbwrapper Goto Github PK
View Code? Open in Web Editor NEWA promise-based wrapper around the indexedDB api
License: MIT License
A promise-based wrapper around the indexedDB api
License: MIT License
I can not createStore/createTable in firefox , could you not upload the new code ? please help me
When using a where condition on an index inside a transaction the error The transaction is not active
is thrown
Would be great to be able to wholesale import/export data.
Example use-case for export would be back up data to Dropbox. Example use-case of import would be to pull that data from dropbox on a new device.
#1 is related to this. The transaction gets closed when it's not actively being used. so chaining where conditions and also just calling find
multiple times before actually executing it, leads to an inactive transaction.
This is due to the fact that a transaction is being commited as soon as no more requests are being placed against it. Since the TransactionWrapper
creates the transaction and then executes the callback, calling where
etc. on the QueryWrapper
does not immediatly create requests and thus the transaction becomes inactive.
So when a store has a keyPath
and autoIncrement
is set to true
, then the store sets the key using the provided keyPath
and thus the key is always returned when selecting the item. Should this be the default also for other stores?
When inserting data like this:
wrapper.insert([{some:data}]).then(...)
wrapper.insert({some:data}, someKey).then(...)
should the key be set on the object? It might help doing that because else we wouldn't know the key for the object in the first insert.
The same goes for selects like this:
wrapper.find().where.index('someIndex').only('something').then(...);
In an autoIncrement
store we will have ids and then could delete some items by key for example. In store which does not use autoincrement keys and does not use a keypath, it would be useful to determine a "default" keyPath on the object and store the returned id there, even though it would not be a real keyPath in the store.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.