Skip to content
This repository has been archived by the owner on Jan 30, 2025. It is now read-only.

Revert "Report all web vital metric changes (#949)" #964

Merged
merged 1 commit into from
Jul 11, 2023

Conversation

ka3de
Copy link
Collaborator

@ka3de ka3de commented Jul 11, 2023

This reverts commit f25b1d4.

Description of changes

In our effort to achieve more consistent Web Vitals reporting, a change was introduced in #949 to force the Web Vitals library to report metrics on every value change. But, in recent tests we have observed that this was an incorrect configuration, especially for LCP metric. LCP measures the time it takes to render the largest image or text block visible within the viewport, relative to when the page first started loading. Because there can only be one "largest" element in a page, LCP should only provide one sample per page load. Instead, if we use the reportAllChanges flag, LCP is reported multiple times when rendering intermediate elements that, up until that point, are the largest rendered in the page. This makes k6 browser record incorrect values for LCP on every new page.

Therefore, we should not use reportAllChanges flag for Web Vitals library.

Related: #960.

@ka3de ka3de self-assigned this Jul 11, 2023
@ka3de ka3de requested a review from ankur22 July 11, 2023 09:59
@ka3de ka3de mentioned this pull request Jun 26, 2023
Copy link
Collaborator

@ankur22 ankur22 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀

@ka3de ka3de merged commit a9bbb79 into main Jul 11, 2023
@ka3de ka3de deleted the revert/wb-reportalways branch July 11, 2023 10:38
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants