Web-Facing Change PSA: Speculation rules: infer "source" if possible

151 views
Skip to first unread message

Jeremy Roman

unread,
Jan 11, 2024, 3:40:16 PMJan 11
to blink-dev

Contact emails

jbr...@chromium.org

Specification

https://wicg.github.io/nav-speculation/speculation-rules.html#parse-a-speculation-rule

Summary

This allows speculation rules to be written more concisely if the type of the rule is not ambiguous (i.e., most cases). For example: {"source":"list","urls":["https://example.com/"]} can be written {"urls":["https://example.com/"]} and {"source":"document","where":{"selector_matches":"#nav > a"}} can be written {"where":{"selector_matches":"#nav > a"}} Existing rules (with explicit "source") continue to work with no change. See https://github.com/WICG/nav-speculation/pull/295.



Blink component

Internals>Preload

TAG review

None

TAG review status

Not applicable

Risks



Interoperability and Compatibility

This is fully backward compatible.



Gecko: No signal

WebKit: No signal

Web developers: No signals

Other signals:

WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?

None



Debuggability

covered by existing developer tools



Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?

No

Is this feature fully tested by web-platform-tests?

Yes

Flag name on chrome://flags

None

Finch feature name

SpeculationRulesImplicitSource

Requires code in //chrome?

False

Tracking bug

https://bugs.chromium.org/p/chromium/issues/detail?id=1517696

Estimated milestones

Shipping on desktop122
Shipping on Android122
Shipping on WebView122


Anticipated spec changes

Open questions about a feature may be a source of future web compat or interop issues. Please list open issues (e.g. links to known github issues in the project for the feature specification) whose resolution may introduce web compat/interop risk (e.g., changing to naming or structure of the API in a non-backward-compatible way).

None

Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5088362954489856

This intent message was generated by Chrome Platform Status.

Reply all
Reply to author
Forward
0 new messages