Consider firing the load/loadend/final readyState events for XHR later during page load (after page load event if possible)
Categories
(Core :: DOM: Networking, enhancement, P2)
Tracking
()
People
(Reporter: smaug, Assigned: smaug)
References
(Blocks 2 open bugs, Regressed 1 open bug)
Details
(Keywords: perf:pageload, site-compat, Whiteboard: [necko-triaged])
Attachments
(2 files, 1 obsolete file)
16.77 KB,
patch
|
Details | Diff | Splinter Review | |
47 bytes,
text/x-phabricator-request
|
Details | Review |
Many pages use XHR during page load, and the final events for such end up firing during the load. That may affect page load time rather heavily.
https://hg.mozilla.org/try/rev/5b88b11dce7f2240bb0dba6a7ec442aa82b9c6a8 is not a well working patch, but just a quick hack to test how much XHR may affect.
Initial results with Gmail don't look too bad, and I can definitely see
the difference locally.
linux https://i.ibb.co/jVGgjs8/image.png
windows https://i.ibb.co/b6Wxh8N/image.png
GDocs and GSlides hero seem to be affected too (but we don't measure loadtime on those ??)
Doesn't seem to affect much to other tp6 sites.
Assignee | ||
Updated•6 years ago
|
Updated•6 years ago
|
Assignee | ||
Comment 1•6 years ago
|
||
Assignee | ||
Comment 2•6 years ago
|
||
Assignee | ||
Comment 3•6 years ago
|
||
And silly mistake fixed.
raptor: https://treeherder.mozilla.org/#/jobs?repo=try&revision=90cb3bfe8f8498a4a539664f69f569e2cda5a03b
tests: https://treeherder.mozilla.org/#/jobs?repo=try&revision=aebb1ada6fbc466682947da405c9a52f03189b8d
Assignee | ||
Comment 4•6 years ago
|
||
We should do something similar to fetch() too, but that is still way less often used.
Assignee | ||
Comment 5•6 years ago
|
||
Assignee | ||
Comment 6•6 years ago
|
||
Updated•6 years ago
|
Comment 8•6 years ago
|
||
bugherder |
Comment 9•6 years ago
|
||
67=wontfix because I assume that XHR changes are too risky to uplift for Firefox/GeckoView 67 Beta (and Fenix MVP).
Updated•5 years ago
|
Comment 10•5 years ago
|
||
Posted site compatibility note: https://www.fxsitecompat.com/en-CA/docs/2019/xhr-load-loadend-readystatechange-events-are-now-deferred-during-page-load/
Updated•3 years ago
|
Description
•