Skip to content

FF115 Add Sec-Purpose HTTP header - #20169

Merged
Elchi3 merged 3 commits into
mdn:mainfrom
hamishwillee:sec_purpose_prefetch
Jun 26, 2023
Merged

Elchi3 merged 3 commits into
mdn:mainfrom
hamishwillee:sec_purpose_prefetch

Conversation

@hamishwillee

@hamishwillee hamishwillee commented Jun 20, 2023 •

Copy link
Copy Markdown
Contributor

FF115 adds support for Sec-Purpose header in https://bugzilla.mozilla.org/show_bug.cgi?id=1836328.

The other browsers are not supported according to https://wpt.fyi/results/preload/prefetch-headers.https.html?label=experimental&label=master&aligned in Chrome 116, Safari 172.

Sec-Purpose: prefetch is the new way to indicate a request is a prefetch request. In Firefox it replaces X-moz: prefetch and in Chromium it will replace Purpose: prefetch, though it has not been implemented yet.

I want to avoid adding data for X-moz: prefetch and Purpose: prefetch as both are effectively non-standard, and it is difficult enough to capture what is happening with Sec-Purpose.

Related docs work can be tracked in mdn/content#27171

@github-actions github-actions Bot added the data:http Compatibility data for HTTP features. https://developer.mozilla.org/docs/Web/HTTP label Jun 20, 2023
"support": {
"chrome": {
"version_added": false,
"notes": "Chrome uses the legacy <code>Purpose: prefetch</code> header to indicate a request is a prefetch. See <a href='https://crbug.com/1358419'>bug 1358419</a>."

@hamishwillee hamishwillee Jun 23, 2023 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not treating Purpose as an alias because I don't know whether it really is - that depends on how it is deprecated, or if it lives in parallel, or what.

Comment thread http/headers/Sec-Purpose.json Resolved
Comment thread http/headers/Sec-Purpose.json Resolved
@hamishwillee

Copy link
Copy Markdown
Contributor Author

FYI @Elchi3 @queengooborg

@Elchi3 Elchi3 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Hamish! 👍

@Elchi3
Elchi3 merged commit 3c4fe19 into mdn:main Jun 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

data:http Compatibility data for HTTP features. https://developer.mozilla.org/docs/Web/HTTP

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants