Skip to content

Speculation rules: form_submission field #1355

@domfarolino

Description

@domfarolino

Specification title

Speculation rules: form_submission field

Specification or proposal URL (if available)

No response

Explainer URL (if available)

https://github.com/WICG/nav-speculation/blob/main/prerendering-form-submission.md

Proposal author(s)

@robertlin-chromium

MDN URL

No response

Caniuse.com URL

No response

Bugzilla URL

No response

Mozillians who can provide input

@zcorpan

WebKit standards-position

WebKit/standards-positions#614

Other information

See https://github.com/WICG/nav-speculation/blob/main/prerendering-form-submission.md. For implementation reasons, Chromium has found it difficult to activate a prerender during a form submission navigation, since form-initiated navigations have extra state and checks associated with them that the original prerender request did not incur.

From peering into other engines's source code, we suspect other browsers may have similar limitations, so we're proposing the form_submission boolean field to indicate whether a prerender request should be processed by the browser as if it were a form submission navigation, so that it can be activated by real form submissions. We'd love to hear if Gecko's speculation rules implementation would have a similar limitation to Chromium—not being able activate a traditional prerender from a form submission navigation.

In a way, this is similar to the target_hint field that Chromium introduced, due to browser complexity of activating prerenders inside different browsing contexts than those that initiated the prerender.

Note that the need for this proposal is not entirely due to browser limitations in form navigation handling. It's also to avoid wasted prerenders when CSP would otherwise prevent form navigations. See the explainer for more details.

/cc @robertlin-chromium @tunetheweb

Metadata

Metadata

Assignees

Labels

topic: APIvenue: W3C CGSpecifications in W3C Community Groups (e.g., WICG, Privacy CG)

Type

No type

Projects

Status

Needs proposed position

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions