[Question] Recommendation for A/B testing a particular JavaScript snippet with Web Vitals Report?
See original GitHub issueHello,
We are looking to implement Core Web Vitals first on our site, then eventually on our clients’ websites. Particularly, we want to measure the web vitals both with and without a particular JavaScript snippet running on the page, and be able to easily compare/contrast these values to understand the UX impact of the snippet.
We can implement a “coin flip” mechanic that determines whether or not to inject the JavaScript, and report on the Core Web Vitals in every case.
It seems like we might somehow be able to take advantage of eventLabel
and grouping (or maybe some other GA event property), but are unsure how we can configure web-vitals-report correctly for this particular use-case.
Are there any recommendations on how to approach this problem? Any help would be greatly appreciated.
Issue Analytics
- State:
- Created 3 years ago
- Comments:5
Top GitHub Comments
Try using a custom date range. If I recall correctly, “Last 7 days” does not include the current day.
@philipwalton - Wow, this is incredibly useful. I hope other stumble upon this as well, as it is invaluable information.
Thanks to your help in getting the UMD+polyfill reporting working (currently working in Chrome), we can start to capture values and set up
web-vitals-report
, at which point I will be able to come back and fully digest this.