← Back to release summary

Implement IDBCursor `request` attribute

Category
Offline / Storage
Type
New or changed feature
Status
Enabled by default (Chrome 76)
Intent stage
Evaluate readiness to ship

Summary

This exposes the underlying IDBRequest of IDBCursor objects. It is a minor addition, exposing previously spec'd behavior.

Motivation

Requests for cursors are different as they can succeed many times. When you call cursor.continue() the success of that operation is provided in the request returned by source.openCursor(). If I want to give an object store to another piece of code, I can just pass the object store. However, if I want to pass the cursor elsewhere, I also have to pass the related request. From this, it is reasonable to expose an IDBCursor's request object as an attribute.

Standards & signals

Docs: No design docs were created for the implementation of this feature

Explainers: https://github.com/w3c/IndexedDB/issues/255#issue-416772452

View on chromestatus.com