-
Notifications
You must be signed in to change notification settings - Fork 719
Define which subresources block the DOM load event #1088
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
Comments
Agenda+ to at least solve the issue of which spec to put this in. :) |
So the tests from web-platform-tests/wpt#5525 show that:
Beyond that, stuff gets less interoperable:
|
This is the bit that says we should define this: Though, really, I would rather not start a discussion about what is critical or what is not. To keep our model sane and automatically up-to-date, I would argue either that any resource downloaded after applying CSS is a critical sub-resource and must be waited on (which means it must be used somewhere on the page before the load event fires otherwise it won't trigger a download), or that no subresource of css is considered critical if it isn't layout-impacting. Based on Geoffrey's findings, Edge has the latter model (we should also delay for fonts though to be consistent) while Chrome has the former model (every subresource is critical). Chrome's model is maybe easier to implement but it delays consequently the load event, which likely has negative perf implications. |
We need some practical way to tell once all subresources to have loaded, regardless of whether this is the load event or otherwise, for the sake of WebDriver and other such testing tools, as we need to make sure there's some way to get a screenshot of a fully loaded page. |
I think you can use the resource timing api. It does require polling though, because you don't get an event when a new resource download starts. |
@FremyCompany that only works in the same-origin case, though |
RESOLVED: Add proposed DOM load events to Values & Units. |
Given the implications on screenshot based testing, we should let the WebDriver WG know if we decide to make it web-platform unobservable when all subresources are loaded. (Note |
Another open question is whether indirectly- I'll be defining something very tentative in HTML in whatwg/html#3544 but it would be great if the CSSWG was able to resolve this one way or another, write the tests, and move the definition into one of their specs. I'll have HTML link to this open issue. |
I think having behavior differences between Another bit that should be defined is when restrictions on use of style sheets such as |
The Working Group just discussed The full IRC log of that discussion |
Chrome delays the load event of Document (which is tested by web-platform-tests/wpt#5525) but not the load event of the Modified @bzbarsky's test case in whatwg/html#3544: fox
">
Perhaps this is because Chrome
|
Uh oh!
There was an error while loading. Please reload this page.
Moving this over from https://www.w3.org/Bugs/Public/show_bug.cgi?id=17011, given that's apparently appropriate nowadays.
CSS should somewhere (hence the lack of any tagged spec!) define which subresources block the load event; at least when that bug was filed IE, Firefox, and Opera blocked the load event on background images and on web fonts loading (which is therefore related to #1082), Safari and Chrome (and this is pre-fork!) didn't, blocking only on
@import
.I believe someone claimed recently that Edge matches Safari and Chrome, making Firefox the odd one out. Someone should, however, test that.
The text was updated successfully, but these errors were encountered: