Open
Description
store.query
opens an IndexedDB transaction and uses a cursor to iterate over each entry in the datastore. The transaction closes automatically when the microtask queue is emptied and there's no outstanding work for it to do, even if the cursor is not at the end of the dataset.
Each query result is yield
ed to the caller which if they do any async work can cause the transaction to close and the next call to cursor.continue()
to throw ERROR: DOMException{stack: 'Error: Failed to execute 'continue' on 'IDBCursor': The transaction is not active.
.
https://www.npmjs.com/package/idb/v/5.0.2#transaction-lifetime