File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
internal/js/modules/k6/browser/common Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -326,6 +326,9 @@ func (fs *FrameSession) onEventBindingCalled(event *cdpruntime.EventBindingCalle
326326 }
327327}
328328
329+ //nolint:gochecknoglobals
330+ var fidDeprecationWarningOnce sync.Once
331+
329332func (fs * FrameSession ) parseAndEmitWebVitalMetric (object string ) error {
330333 fs .logger .Debugf ("FrameSession:parseAndEmitWebVitalMetric" , "object:%s" , object )
331334
@@ -345,6 +348,12 @@ func (fs *FrameSession) parseAndEmitWebVitalMetric(object string) error {
345348 return fmt .Errorf ("json couldn't be parsed: %w" , err )
346349 }
347350
351+ if wv .Name == "FID" {
352+ fidDeprecationWarningOnce .Do (func () {
353+ fs .logger .Warnf ("MetricDeprecation" , "browser_web_vital_fid has been deprecated and superseded by browser_web_vital_inp" )
354+ })
355+ }
356+
348357 metric , ok := fs .k6Metrics .WebVitals [wv .Name ]
349358 if ! ok {
350359 return fmt .Errorf ("metric not registered %q" , wv .Name )
You can’t perform that action at this time.
0 commit comments