hlxsites / servicenow

Apache License 2.0
2 stars 3 forks source link

fix - Optimise LCP score in the homepage #154

Closed andreituicu closed 10 months ago

andreituicu commented 11 months ago

The default logic for awaiting the LCP image doesn't work well for blogs home page, as it is waiting for the first image present in the dom to load, which in that case, is in the sidebar. For the best LCP load time, we need to skip that waiting, quickly load the first card teaser and then wait for that image to load.

Before: LCP 1.7 - 2.2. LHS Score 99 - 100. After: LCP 1.4 - 1.7. LHS Score 100.

Test URLs:

aem-code-sync[bot] commented 11 months ago

Hello, I'm the AEM Code Sync Bot and I will run some test suites that validate the page speed. In case there are problems, just click the checkbox below to rerun the respective action.

aem-code-sync[bot] commented 11 months ago
Page Scores Audits Google
/blogs PERFORMANCE A11Y SEO BEST PRACTICES SI FCP LCP TBT CLS PSI
aem-code-sync[bot] commented 11 months ago
Page Scores Audits Google
/blogs PERFORMANCE A11Y SEO BEST PRACTICES SI FCP LCP TBT CLS PSI
aem-code-sync[bot] commented 11 months ago
Page Scores Audits Google
/blogs PERFORMANCE A11Y SEO BEST PRACTICES SI FCP LCP TBT CLS PSI