Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf(common): monitor LCP only for images without
priority
attribute (
#47082) This commit optimizes the logic that monitors whether a give image is an LCP element. If an image has the `priority` attribute set, there is no need to include it into monitoring. Also, if we already warned about a particular image (via a `console.warn`) - there is no need to warn again later (to avoid spamming a console). PR Close #47082
- Loading branch information
1 parent
37e3a60
commit 0c8eb8b
Showing
1 changed file
with
38 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters