-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
🚀 [Story performance] Experiment to load first page assets before loading other pages to improve LCP #34846
Conversation
Hey @gmajoulet, @newmuis! These files were changed:
|
1 similar comment
Hey @gmajoulet, @newmuis! These files were changed:
|
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.
Can you launch this behind a CSI reported experiment so we can gather performance metrics?
@kristoferbaxter will remove the logs 👍 |
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.
Left a few comments, but let's also get @jridgewell or @erwinmombay to take a look.
Perhaps for some period of time asking @ampproject/wg-performance for reviews on performance related changes to the stories format would be prudent.
Can you clarify what you're measuring in the metrics you're posted? A LCP of 0.5s without any optimization is very very surprising to me |
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.
It seems instead of "prealoding all" (parallel), it should just use serial preloading? Ie, prioritize based on distance.
Before moving forward here, as an additional verification can you provide a few runs (9 is likely ok) on WebPageTest of this diff on a midrange device? |
@kristoferbaxter thanks for the suggestion, didn't know about WebPageTest. Added the results to the PR description but here they are: LCP field data from WebPageTestLCP with change 10.09s |
@mszylkowski can you send a follow up PR to launch this to 10% plz? We can control further using the new instant experiment system later on once it's back, but for this one let's use the regular experiments. |
For reference: Launching experiment to 10% in #35192 |
In order to improve the Largest Contentful Paint which is the major failing component of the Core Web Vitals for stories, we can delay the loading of the assets (images, audios and videos) on the inactive pages until the active page (the first page that shows up when the story is loaded).
Since we use the

distance
attribute to determine what to load, following pages will not show up until the active page appears, or we navigate to another page.LCP lab data for this PR
LCP field data from WebPageTest
LCP with change 10.09s
LCP without change 11.07s