github web-platform-tests/wpt merge_pr_49486

latest releases: merge_pr_49470, epochs/three_hourly/2024-12-03_06H, epochs/six_hourly/2024-12-03_06H...
18 days ago

[shared storage] Add SharedStorageSet/Append/Delete/Clear IDL Interface

Implement the constructor for SharedStorageSetMethod, etc. The
error handling logic mirrors the existing sharedStorage.set(), etc.
To allow code reuse, the sharedStorage.set(), etc. methods
now creates the object and early return on exceptions.

Note that even though we no longer explicitly call resolver->Reject()
for sharedStorage.set(), etc., Chrome still converts thrown
exceptions to rejected promises (to adhere to the specification [1]),
so the end result is the same.

This prepares for the implementation of the
sharedStorage.batchUpdate(methods) method, as part of the Web Lock
integration proposal:

[1] https://w3ctag.github.io/promises-guide/#always-return-promises

Bug: 373899210
Change-Id: Ie4edfedbe755afeb3db5ca557fd74482bac96138
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6054694
Commit-Queue: Yao Xiao yaoxia@chromium.org
Reviewed-by: Cammie Smith Barnes cammie@chromium.org
Cr-Commit-Position: refs/heads/main@{#1390779}

Don't miss a new wpt release

NewReleases is sending notifications on new releases.