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
Request for review: Preload #202
Comments
I was just thinking about to bring up the review with you folks. Thanks for submitting. |
Hi @yoavweiss, Thanks for raising this review with us, and congrats on the adoption. We have three points of feedback:
|
Review raised, completed and closed within 24 hours. This is a TAG record. |
👏 👍
That's not true, and we learned this the hard way a few times over now. Browsers that support WebP should (and do) advertise webp on all requests; same best practice applies to all other formats.
No it's not, but we can probably make prefetch better and smarter. In terms of differences, preload and prefetch serve different purposes. Addy and Yoav have good explainers here:
Open to suggestions on how to explain prefetch better, let's route that feedback into Resource Hints spec. |
My testing indicates that browsers do send different Accept headers based on the instigator of the request (and in the case of preload, the value of |
I think you both are talking about different things. What @igrigorik is saying is that when preload is used as a browser signal, the browser will send the appropriate IIUC, @triblondon is talking about using preload as a push signal, and lack of content-negotiation in that case. That's not a problem with preload, as no markup or server side mechanism could have helped here. HTTP/2 push cannot perform content negotiation, as by definition the client does not take part in the generation of the request. That's one of the advantages of preload over push. |
My thinking is that maybe we need a mechanism in http/2 where the client can pre-send accept headers for other resource types (possibly prompted by the server before it does the push) so the server can make the push match what the client would have negotiated via a normal fetch. This is obviously an issue for http/2 rather than preload and I'll follow up there. |
For the record, the Accept header in Chrome for navigation requests (which will be available to a push-enabled server) does contain the supported image formats as well:
I don't know if that is standardised and intended to be used for this purpose, but it is one possible way to inform servers of supported formats of sub resources. For the case of other non-image files (such as fonts) this wouldn't suffice right now. For fonts, preload has a |
Hello TAG!
I'm requesting a TAG review of:
Further details:
You should also know that the feature already has shipping implementations in 2.5 browsers (Chrome, Firefox 57 and Safari Tech Preview). It is also used by 0.9% of page views.
We'd prefer the TAG provide feedback as (please select one):
The text was updated successfully, but these errors were encountered: