You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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.
No objections here. It sounds like we're just exposing a property that is already initialized as part of the cursor and should live as long as the cursor.
Did my thumbs-up not say it all? ;) This sounds good from a Gecko/Firefox perspective. We have the request available and Jake's magical upgrade use-case sounds both reasonable and essential to help move IDB forward from an API that only an implementer could love to the favorite API of developers everywhere!
Reacted by Jake Archibald and Pauline Nemchak
Reacted by Jake Archibald, Joshua Bell, Mark Tomlin, Danilo Fuchs, Pauline Nemchak and Joel Mason
Reacted by Timo Mühlbach, Kristoffer Lindström, Trent Monahan, Vinícius Lemes, Nicola Dal Maso, Brendan McGuire, Belan, Dennis Kugelmann, Jonas Kuske, Theo and 6 more
Reacted by Marceline Szmadzinski, Ståle Raknes, Grzegorz Bielski, Michael Richins, Martino di Filippo, Kristoffer Lindström, Forge, Trent Monahan, Mark Tomlin, Belan and 12 more
Activity
inexorabletash commentedon Mar 4, 2019
I've run into wanting this for prollyfills. SGTM.
Should be easy to spec/test/ship.
jakearchibald commentedon Mar 5, 2019
Yeah, I ran into this trying to make
wrap()andunwrap()functions that 'upgrade' IDB objects. Works for everything except cursors.jakearchibald commentedon Mar 6, 2019
I'll take this on.
I've been wanting to document how standards are developed for a while, so @surma and I will film ourselves updating the spec and writing tests.
inexorabletash commentedon Mar 6, 2019
@asutherland @aliams @beidson - any feedback on this?
aliams commentedon Mar 6, 2019
No objections here. It sounds like we're just exposing a property that is already initialized as part of the cursor and should live as long as the cursor.
asutherland commentedon Mar 6, 2019
Did my thumbs-up not say it all? ;) This sounds good from a Gecko/Firefox perspective. We have the request available and Jake's magical upgrade use-case sounds both reasonable and essential to help move IDB forward from an API that only an implementer could love to the favorite API of developers everywhere!
beidson commentedon Mar 6, 2019
yah this is fine.
inexorabletash commentedon Mar 6, 2019
Thumbs everywhere! Thanks all!
Thanks @jakearchibald and @surma - looking forward to the PRs. Blink change should be trivial once WPTs are in.
Add cursor.request (#257)
inexorabletash commentedon Mar 18, 2019
Filed https://bugs.chromium.org/p/chromium/issues/detail?id=943344 to track Blink impl
asutherland commentedon Mar 19, 2019
Filed https://bugzilla.mozilla.org/show_bug.cgi?id=1536540 to track Gecko/Firefox impl.
Soviut commentedon Apr 16, 2019
For posterity, here's the episode @jakearchibald and @surma did about this very issue https://www.youtube.com/watch?v=y1TEPQz02iU
inexorabletash commentedon May 3, 2019
FYI, @Yannic's change just landed in the Chromium repo so this should be available for testing in the next Chrome Canary build.
julienw commentedon Apr 27, 2020
Just landed in Firefox!
inexorabletash commentedon Apr 27, 2020
Hey @julienw - if you know the prospective Firefox release number I can add it to the "under construction" box https://w3c.github.io/IndexedDB/#dom-idbcursor-request
asutherland commentedon Apr 27, 2020
https://bugzilla.mozilla.org/show_bug.cgi?id=1536540 is fixed in Firefox 77, targeted to reach release ~ June 2nd
Add cursor.request (#257)