-
Notifications
You must be signed in to change notification settings - Fork 22.7k
Add docs for Speculation Rules features: target_hint and clear-site-data #39652
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add docs for Speculation Rules features: target_hint and clear-site-data #39652
Conversation
…t and clear-site-data
Preview URLs
Flaws (3)Note! 2 documents with no flaws that don't need to be listed. 🎉 URL:
(comment last updated: 2025-05-30 04:09:59) |
files/en-us/web/http/reference/headers/clear-site-data/index.md
Outdated
Show resolved
Hide resolved
files/en-us/web/http/reference/headers/clear-site-data/index.md
Outdated
Show resolved
Hide resolved
files/en-us/web/http/reference/headers/clear-site-data/index.md
Outdated
Show resolved
Hide resolved
files/en-us/web/http/reference/headers/clear-site-data/index.md
Outdated
Show resolved
Hide resolved
files/en-us/web/html/reference/elements/script/type/speculationrules/index.md
Outdated
Show resolved
Hide resolved
files/en-us/web/html/reference/elements/script/type/speculationrules/index.md
Outdated
Show resolved
Hide resolved
files/en-us/web/html/reference/elements/script/type/speculationrules/index.md
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @tunetheweb - looks pretty clear to me. I've added some suggestions for discussion. I'd like to see the BCD go in before we push this in if possible.
Co-authored-by: Hamish Willee <[email protected]>
Co-authored-by: Hamish Willee <[email protected]>
Co-authored-by: Hamish Willee <[email protected]>
…nrules/index.md Co-authored-by: Hamish Willee <[email protected]>
…nrules/index.md Co-authored-by: Hamish Willee <[email protected]>
…nrules/index.md Co-authored-by: Hamish Willee <[email protected]>
Co-authored-by: Hamish Willee <[email protected]>
SGTM. I opened both together so I’d know the anchor links when adding to BCD but yeah let’s wait until both are ready to merge. Plus a few things still open in this PR to resolve. |
…nrules/index.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…nrules/index.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…nrules/index.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
files/en-us/web/http/reference/headers/clear-site-data/index.md
Outdated
Show resolved
Hide resolved
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@hamishwillee could you take another look? Also the BCD PR (mdn/browser-compat-data#26893) has been merged now so you can merge this too if you're happy with the changes. |
…ub.com:tunetheweb/content into speculation-rules-target-hints-clear-site-data
files/en-us/web/html/reference/elements/script/type/speculationrules/index.md
Outdated
Show resolved
Hide resolved
…nrules/index.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
For example, a client-side rendered application that pulls in data from JavaScript might use `prerenderCache` on state change to discard the prerendered pages, but keep the prefetched HTML to use when the page is rendered (or prerendered again). | ||
|
||
On the other hand, if the prefetched HTML document contains stale data but the corresponding prerendered page is set up to refresh the data when it is displayed, you may not need to use `prerenderCache` but you probably will want to use the `prefetchCache` directive: so that the stale HTML isn't used in a future prerender. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI I did a minor subedit around this bit to refer to prefetched HTML document rather than just "HTML document". I know they are the same thing, but mentioning "prefetch" here makes directly associates this HTML document in my mind with the relevant directive.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks very much @tunetheweb
The last round of changes you did look good. I was interested to see the change regarding targets in where
not being needed. Make sense.
FYI I work Mon, Tue, Friday on this stuff. Sometimes I might take longer than you expect to rereview. Sorry!
No bother at all! It's rarely super critical to get these in (and will make it clear if it ever is) and much more important to be right. In this case for example I'm actually well ahead of the game as Chrome 138 (where these changes are landing) is still a few weeks out. Thanks so much for your help in polishing this. Much better for you feedback. |
Description
Chrome 138 will add two new features for Speculation Rules:
target_hint
clear-site-data
Motivation
New features
Additional details
target_hint
Chrome Status link: https://chromestatus.com/feature/5162540351094784
Explainer link: https://github.com/WICG/nav-speculation/blob/main/triggers.md#window-name-targeting-hints
Clear-site-data
Chrome Status link: https://chromestatus.com/feature/4755745652080640
Explainer link: https://github.com/WICG/nav-speculation/blob/main/clear-site-data-integration.md
Related issues and pull requests
BCD PR: mdn/browser-compat-data#26893