@sentry/browser-utils 10.70.0 → 11.0.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/htmlTreeAsString.js.map +1 -1
- package/build/cjs/index.js +30 -28
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/instrumentation/dom.js.map +1 -0
- package/build/cjs/instrumentation/history.js.map +1 -0
- package/build/cjs/instrumentation/location.js.map +1 -0
- package/build/cjs/{metrics/instrument.js → instrumentation/performanceObserver.js} +44 -32
- package/build/cjs/instrumentation/performanceObserver.js.map +1 -0
- package/build/cjs/instrumentation/xhr.js.map +1 -0
- package/build/cjs/{metrics → performance}/elementTiming.js +2 -2
- package/build/cjs/performance/elementTiming.js.map +1 -0
- package/build/cjs/{metrics/browserMetrics.js → performance/entries.js} +43 -262
- package/build/cjs/performance/entries.js.map +1 -0
- package/build/cjs/performance/resourceTiming.js.map +1 -0
- package/build/cjs/performance/userTiming.js +119 -0
- package/build/cjs/performance/userTiming.js.map +1 -0
- package/build/cjs/performance/utils.js +68 -0
- package/build/cjs/performance/utils.js.map +1 -0
- package/build/cjs/{metrics → web-vitals}/inp.js +4 -61
- package/build/cjs/web-vitals/inp.js.map +1 -0
- package/build/cjs/web-vitals/lcp.js +10 -0
- package/build/cjs/web-vitals/lcp.js.map +1 -0
- package/build/cjs/web-vitals/reportEvents.js +31 -0
- package/build/cjs/web-vitals/reportEvents.js.map +1 -0
- package/build/cjs/{metrics/webVitalSpans.js → web-vitals/spans.js} +36 -19
- package/build/cjs/web-vitals/spans.js.map +1 -0
- package/build/cjs/web-vitals/tracking.js +164 -0
- package/build/cjs/web-vitals/tracking.js.map +1 -0
- package/build/cjs/web-vitals/utils.js +99 -0
- package/build/cjs/web-vitals/utils.js.map +1 -0
- package/build/esm/htmlTreeAsString.js.map +1 -1
- package/build/esm/index.js +14 -12
- package/build/esm/index.js.map +1 -1
- package/build/esm/instrumentation/dom.js.map +1 -0
- package/build/esm/instrumentation/history.js.map +1 -0
- package/build/esm/instrumentation/location.js.map +1 -0
- package/build/esm/{metrics/instrument.js → instrumentation/performanceObserver.js} +42 -30
- package/build/esm/instrumentation/performanceObserver.js.map +1 -0
- package/build/esm/instrumentation/xhr.js.map +1 -0
- package/build/esm/package.json +1 -1
- package/build/esm/{metrics → performance}/elementTiming.js +1 -1
- package/build/esm/performance/elementTiming.js.map +1 -0
- package/build/esm/{metrics/browserMetrics.js → performance/entries.js} +36 -252
- package/build/esm/performance/entries.js.map +1 -0
- package/build/esm/performance/resourceTiming.js.map +1 -0
- package/build/esm/performance/userTiming.js +116 -0
- package/build/esm/performance/userTiming.js.map +1 -0
- package/build/esm/performance/utils.js +61 -0
- package/build/esm/performance/utils.js.map +1 -0
- package/build/esm/{metrics → web-vitals}/inp.js +3 -57
- package/build/esm/web-vitals/inp.js.map +1 -0
- package/build/esm/web-vitals/lcp.js +7 -0
- package/build/esm/web-vitals/lcp.js.map +1 -0
- package/build/esm/web-vitals/reportEvents.js +29 -0
- package/build/esm/web-vitals/reportEvents.js.map +1 -0
- package/build/esm/{metrics/webVitalSpans.js → web-vitals/spans.js} +32 -15
- package/build/esm/web-vitals/spans.js.map +1 -0
- package/build/esm/web-vitals/tracking.js +161 -0
- package/build/esm/web-vitals/tracking.js.map +1 -0
- package/build/esm/web-vitals/utils.js +91 -0
- package/build/esm/web-vitals/utils.js.map +1 -0
- package/build/types/index.d.ts +13 -11
- package/build/types/index.d.ts.map +1 -1
- package/build/types/instrumentation/dom.d.ts.map +1 -0
- package/build/types/instrumentation/history.d.ts.map +1 -0
- package/build/types/instrumentation/location.d.ts.map +1 -0
- package/build/types/{metrics/instrument.d.ts → instrumentation/performanceObserver.d.ts} +3 -3
- package/build/types/instrumentation/performanceObserver.d.ts.map +1 -0
- package/build/types/instrumentation/xhr.d.ts.map +1 -0
- package/build/types/performance/elementTiming.d.ts.map +1 -0
- package/build/types/performance/entries.d.ts +49 -0
- package/build/types/performance/entries.d.ts.map +1 -0
- package/build/types/performance/resourceTiming.d.ts.map +1 -0
- package/build/types/performance/userTiming.d.ts +37 -0
- package/build/types/performance/userTiming.d.ts.map +1 -0
- package/build/types/performance/utils.d.ts +33 -0
- package/build/types/performance/utils.d.ts.map +1 -0
- package/build/types/types.d.ts +1 -1
- package/build/types/{metrics → web-vitals}/inp.d.ts +0 -13
- package/build/types/web-vitals/inp.d.ts.map +1 -0
- package/build/types/web-vitals/lcp.d.ts +6 -0
- package/build/types/web-vitals/lcp.d.ts.map +1 -0
- package/build/types/web-vitals/reportEvents.d.ts +18 -0
- package/build/types/web-vitals/reportEvents.d.ts.map +1 -0
- package/build/types/{metrics/webVitalSpans.d.ts → web-vitals/spans.d.ts} +18 -12
- package/build/types/web-vitals/spans.d.ts.map +1 -0
- package/build/types/web-vitals/tracking.d.ts +46 -0
- package/build/types/web-vitals/tracking.d.ts.map +1 -0
- package/build/types/{metrics/web-vitals/lib/globalListeners.d.ts → web-vitals/utils.d.ts} +16 -1
- package/build/types/web-vitals/utils.d.ts.map +1 -0
- package/package.json +8 -16
- package/build/cjs/instrument/dom.js.map +0 -1
- package/build/cjs/instrument/history.js.map +0 -1
- package/build/cjs/instrument/location.js.map +0 -1
- package/build/cjs/instrument/xhr.js.map +0 -1
- package/build/cjs/metrics/browserMetrics.js.map +0 -1
- package/build/cjs/metrics/cls.js +0 -64
- package/build/cjs/metrics/cls.js.map +0 -1
- package/build/cjs/metrics/elementTiming.js.map +0 -1
- package/build/cjs/metrics/inp.js.map +0 -1
- package/build/cjs/metrics/instrument.js.map +0 -1
- package/build/cjs/metrics/lcp.js +0 -77
- package/build/cjs/metrics/lcp.js.map +0 -1
- package/build/cjs/metrics/resourceTiming.js.map +0 -1
- package/build/cjs/metrics/utils.js +0 -137
- package/build/cjs/metrics/utils.js.map +0 -1
- package/build/cjs/metrics/web-vitals/getCLS.js +0 -46
- package/build/cjs/metrics/web-vitals/getCLS.js.map +0 -1
- package/build/cjs/metrics/web-vitals/getINP.js +0 -60
- package/build/cjs/metrics/web-vitals/getINP.js.map +0 -1
- package/build/cjs/metrics/web-vitals/getLCP.js +0 -62
- package/build/cjs/metrics/web-vitals/getLCP.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/InteractionManager.js +0 -87
- package/build/cjs/metrics/web-vitals/lib/InteractionManager.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/LCPEntryManager.js +0 -11
- package/build/cjs/metrics/web-vitals/lib/LCPEntryManager.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/LayoutShiftManager.js +0 -27
- package/build/cjs/metrics/web-vitals/lib/LayoutShiftManager.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/bindReporter.js +0 -31
- package/build/cjs/metrics/web-vitals/lib/bindReporter.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/generateUniqueID.js +0 -8
- package/build/cjs/metrics/web-vitals/lib/generateUniqueID.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/getActivationStart.js +0 -11
- package/build/cjs/metrics/web-vitals/lib/getActivationStart.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/getNavigationEntry.js +0 -17
- package/build/cjs/metrics/web-vitals/lib/getNavigationEntry.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/getVisibilityWatcher.js +0 -48
- package/build/cjs/metrics/web-vitals/lib/getVisibilityWatcher.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/globalListeners.js +0 -18
- package/build/cjs/metrics/web-vitals/lib/globalListeners.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/initMetric.js +0 -34
- package/build/cjs/metrics/web-vitals/lib/initMetric.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/initUnique.js +0 -16
- package/build/cjs/metrics/web-vitals/lib/initUnique.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/observe.js +0 -20
- package/build/cjs/metrics/web-vitals/lib/observe.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/onHidden.js +0 -17
- package/build/cjs/metrics/web-vitals/lib/onHidden.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/polyfills/interactionCountPolyfill.js +0 -32
- package/build/cjs/metrics/web-vitals/lib/polyfills/interactionCountPolyfill.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/runOnce.js +0 -14
- package/build/cjs/metrics/web-vitals/lib/runOnce.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/whenActivated.js +0 -14
- package/build/cjs/metrics/web-vitals/lib/whenActivated.js.map +0 -1
- package/build/cjs/metrics/web-vitals/lib/whenIdleOrHidden.js +0 -24
- package/build/cjs/metrics/web-vitals/lib/whenIdleOrHidden.js.map +0 -1
- package/build/cjs/metrics/web-vitals/onFCP.js +0 -37
- package/build/cjs/metrics/web-vitals/onFCP.js.map +0 -1
- package/build/cjs/metrics/web-vitals/onTTFB.js +0 -35
- package/build/cjs/metrics/web-vitals/onTTFB.js.map +0 -1
- package/build/cjs/metrics/webVitalSpans.js.map +0 -1
- package/build/esm/instrument/dom.js.map +0 -1
- package/build/esm/instrument/history.js.map +0 -1
- package/build/esm/instrument/location.js.map +0 -1
- package/build/esm/instrument/xhr.js.map +0 -1
- package/build/esm/metrics/browserMetrics.js.map +0 -1
- package/build/esm/metrics/cls.js +0 -61
- package/build/esm/metrics/cls.js.map +0 -1
- package/build/esm/metrics/elementTiming.js.map +0 -1
- package/build/esm/metrics/inp.js.map +0 -1
- package/build/esm/metrics/instrument.js.map +0 -1
- package/build/esm/metrics/lcp.js +0 -72
- package/build/esm/metrics/lcp.js.map +0 -1
- package/build/esm/metrics/resourceTiming.js.map +0 -1
- package/build/esm/metrics/utils.js +0 -128
- package/build/esm/metrics/utils.js.map +0 -1
- package/build/esm/metrics/web-vitals/getCLS.js +0 -43
- package/build/esm/metrics/web-vitals/getCLS.js.map +0 -1
- package/build/esm/metrics/web-vitals/getINP.js +0 -57
- package/build/esm/metrics/web-vitals/getINP.js.map +0 -1
- package/build/esm/metrics/web-vitals/getLCP.js +0 -59
- package/build/esm/metrics/web-vitals/getLCP.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/InteractionManager.js +0 -85
- package/build/esm/metrics/web-vitals/lib/InteractionManager.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/LCPEntryManager.js +0 -9
- package/build/esm/metrics/web-vitals/lib/LCPEntryManager.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/LayoutShiftManager.js +0 -25
- package/build/esm/metrics/web-vitals/lib/LayoutShiftManager.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/bindReporter.js +0 -29
- package/build/esm/metrics/web-vitals/lib/bindReporter.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/generateUniqueID.js +0 -6
- package/build/esm/metrics/web-vitals/lib/generateUniqueID.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/getActivationStart.js +0 -9
- package/build/esm/metrics/web-vitals/lib/getActivationStart.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/getNavigationEntry.js +0 -15
- package/build/esm/metrics/web-vitals/lib/getNavigationEntry.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/getVisibilityWatcher.js +0 -46
- package/build/esm/metrics/web-vitals/lib/getVisibilityWatcher.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/globalListeners.js +0 -15
- package/build/esm/metrics/web-vitals/lib/globalListeners.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/initMetric.js +0 -32
- package/build/esm/metrics/web-vitals/lib/initMetric.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/initUnique.js +0 -14
- package/build/esm/metrics/web-vitals/lib/initUnique.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/observe.js +0 -18
- package/build/esm/metrics/web-vitals/lib/observe.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/onHidden.js +0 -15
- package/build/esm/metrics/web-vitals/lib/onHidden.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/polyfills/interactionCountPolyfill.js +0 -29
- package/build/esm/metrics/web-vitals/lib/polyfills/interactionCountPolyfill.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/runOnce.js +0 -12
- package/build/esm/metrics/web-vitals/lib/runOnce.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/whenActivated.js +0 -12
- package/build/esm/metrics/web-vitals/lib/whenActivated.js.map +0 -1
- package/build/esm/metrics/web-vitals/lib/whenIdleOrHidden.js +0 -22
- package/build/esm/metrics/web-vitals/lib/whenIdleOrHidden.js.map +0 -1
- package/build/esm/metrics/web-vitals/onFCP.js +0 -34
- package/build/esm/metrics/web-vitals/onFCP.js.map +0 -1
- package/build/esm/metrics/web-vitals/onTTFB.js +0 -32
- package/build/esm/metrics/web-vitals/onTTFB.js.map +0 -1
- package/build/esm/metrics/webVitalSpans.js.map +0 -1
- package/build/types/instrument/dom.d.ts.map +0 -1
- package/build/types/instrument/history.d.ts.map +0 -1
- package/build/types/instrument/location.d.ts.map +0 -1
- package/build/types/instrument/xhr.d.ts.map +0 -1
- package/build/types/metrics/browserMetrics.d.ts +0 -116
- package/build/types/metrics/browserMetrics.d.ts.map +0 -1
- package/build/types/metrics/cls.d.ts +0 -17
- package/build/types/metrics/cls.d.ts.map +0 -1
- package/build/types/metrics/elementTiming.d.ts.map +0 -1
- package/build/types/metrics/inp.d.ts.map +0 -1
- package/build/types/metrics/instrument.d.ts.map +0 -1
- package/build/types/metrics/lcp.d.ts +0 -22
- package/build/types/metrics/lcp.d.ts.map +0 -1
- package/build/types/metrics/resourceTiming.d.ts.map +0 -1
- package/build/types/metrics/utils.d.ts +0 -73
- package/build/types/metrics/utils.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/getCLS.d.ts +0 -26
- package/build/types/metrics/web-vitals/getCLS.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/getINP.d.ts +0 -34
- package/build/types/metrics/web-vitals/getINP.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/getLCP.d.ts +0 -16
- package/build/types/metrics/web-vitals/getLCP.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/InteractionManager.d.ts +0 -37
- package/build/types/metrics/web-vitals/lib/InteractionManager.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/LCPEntryManager.d.ts +0 -5
- package/build/types/metrics/web-vitals/lib/LCPEntryManager.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/LayoutShiftManager.d.ts +0 -7
- package/build/types/metrics/web-vitals/lib/LayoutShiftManager.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/bindReporter.d.ts +0 -7
- package/build/types/metrics/web-vitals/lib/bindReporter.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/generateUniqueID.d.ts +0 -7
- package/build/types/metrics/web-vitals/lib/generateUniqueID.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/getActivationStart.d.ts +0 -2
- package/build/types/metrics/web-vitals/lib/getActivationStart.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/getNavigationEntry.d.ts +0 -2
- package/build/types/metrics/web-vitals/lib/getNavigationEntry.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/getVisibilityWatcher.d.ts +0 -5
- package/build/types/metrics/web-vitals/lib/getVisibilityWatcher.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/globalListeners.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/initMetric.d.ts +0 -21
- package/build/types/metrics/web-vitals/lib/initMetric.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/initUnique.d.ts +0 -7
- package/build/types/metrics/web-vitals/lib/initUnique.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/observe.d.ts +0 -23
- package/build/types/metrics/web-vitals/lib/observe.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/onHidden.d.ts +0 -27
- package/build/types/metrics/web-vitals/lib/onHidden.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/polyfills/interactionCountPolyfill.d.ts +0 -15
- package/build/types/metrics/web-vitals/lib/polyfills/interactionCountPolyfill.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/runOnce.d.ts +0 -2
- package/build/types/metrics/web-vitals/lib/runOnce.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/whenActivated.d.ts +0 -2
- package/build/types/metrics/web-vitals/lib/whenActivated.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/lib/whenIdleOrHidden.d.ts +0 -6
- package/build/types/metrics/web-vitals/lib/whenIdleOrHidden.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/onFCP.d.ts +0 -11
- package/build/types/metrics/web-vitals/onFCP.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/onTTFB.d.ts +0 -20
- package/build/types/metrics/web-vitals/onTTFB.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/types/base.d.ts +0 -103
- package/build/types/metrics/web-vitals/types/base.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/types/cls.d.ts +0 -58
- package/build/types/metrics/web-vitals/types/cls.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/types/fcp.d.ts +0 -47
- package/build/types/metrics/web-vitals/types/fcp.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/types/inp.d.ts +0 -150
- package/build/types/metrics/web-vitals/types/inp.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/types/lcp.d.ts +0 -74
- package/build/types/metrics/web-vitals/types/lcp.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/types/ttfb.d.ts +0 -60
- package/build/types/metrics/web-vitals/types/ttfb.d.ts.map +0 -1
- package/build/types/metrics/web-vitals/types.d.ts +0 -78
- package/build/types/metrics/web-vitals/types.d.ts.map +0 -1
- package/build/types/metrics/webVitalSpans.d.ts.map +0 -1
- package/build/types-ts3.8/debug-build.d.ts +0 -7
- package/build/types-ts3.8/getNativeImplementation.d.ts +0 -69
- package/build/types-ts3.8/htmlTreeAsString.d.ts +0 -11
- package/build/types-ts3.8/index.d.ts +0 -17
- package/build/types-ts3.8/instrument/dom.d.ts +0 -11
- package/build/types-ts3.8/instrument/history.d.ts +0 -15
- package/build/types-ts3.8/instrument/location.d.ts +0 -13
- package/build/types-ts3.8/instrument/xhr.d.ts +0 -14
- package/build/types-ts3.8/is.d.ts +0 -7
- package/build/types-ts3.8/metrics/browserMetrics.d.ts +0 -119
- package/build/types-ts3.8/metrics/cls.d.ts +0 -17
- package/build/types-ts3.8/metrics/elementTiming.d.ts +0 -21
- package/build/types-ts3.8/metrics/inp.d.ts +0 -35
- package/build/types-ts3.8/metrics/instrument.d.ts +0 -121
- package/build/types-ts3.8/metrics/lcp.d.ts +0 -22
- package/build/types-ts3.8/metrics/resourceTiming.d.ts +0 -13
- package/build/types-ts3.8/metrics/utils.d.ts +0 -73
- package/build/types-ts3.8/metrics/web-vitals/getCLS.d.ts +0 -26
- package/build/types-ts3.8/metrics/web-vitals/getINP.d.ts +0 -34
- package/build/types-ts3.8/metrics/web-vitals/getLCP.d.ts +0 -16
- package/build/types-ts3.8/metrics/web-vitals/lib/InteractionManager.d.ts +0 -37
- package/build/types-ts3.8/metrics/web-vitals/lib/LCPEntryManager.d.ts +0 -5
- package/build/types-ts3.8/metrics/web-vitals/lib/LayoutShiftManager.d.ts +0 -7
- package/build/types-ts3.8/metrics/web-vitals/lib/bindReporter.d.ts +0 -7
- package/build/types-ts3.8/metrics/web-vitals/lib/generateUniqueID.d.ts +0 -7
- package/build/types-ts3.8/metrics/web-vitals/lib/getActivationStart.d.ts +0 -2
- package/build/types-ts3.8/metrics/web-vitals/lib/getNavigationEntry.d.ts +0 -2
- package/build/types-ts3.8/metrics/web-vitals/lib/getVisibilityWatcher.d.ts +0 -5
- package/build/types-ts3.8/metrics/web-vitals/lib/globalListeners.d.ts +0 -11
- package/build/types-ts3.8/metrics/web-vitals/lib/initMetric.d.ts +0 -21
- package/build/types-ts3.8/metrics/web-vitals/lib/initUnique.d.ts +0 -7
- package/build/types-ts3.8/metrics/web-vitals/lib/observe.d.ts +0 -23
- package/build/types-ts3.8/metrics/web-vitals/lib/onHidden.d.ts +0 -27
- package/build/types-ts3.8/metrics/web-vitals/lib/polyfills/interactionCountPolyfill.d.ts +0 -15
- package/build/types-ts3.8/metrics/web-vitals/lib/runOnce.d.ts +0 -2
- package/build/types-ts3.8/metrics/web-vitals/lib/whenActivated.d.ts +0 -2
- package/build/types-ts3.8/metrics/web-vitals/lib/whenIdleOrHidden.d.ts +0 -6
- package/build/types-ts3.8/metrics/web-vitals/onFCP.d.ts +0 -11
- package/build/types-ts3.8/metrics/web-vitals/onTTFB.d.ts +0 -20
- package/build/types-ts3.8/metrics/web-vitals/types/base.d.ts +0 -106
- package/build/types-ts3.8/metrics/web-vitals/types/cls.d.ts +0 -58
- package/build/types-ts3.8/metrics/web-vitals/types/fcp.d.ts +0 -47
- package/build/types-ts3.8/metrics/web-vitals/types/inp.d.ts +0 -150
- package/build/types-ts3.8/metrics/web-vitals/types/lcp.d.ts +0 -74
- package/build/types-ts3.8/metrics/web-vitals/types/ttfb.d.ts +0 -60
- package/build/types-ts3.8/metrics/web-vitals/types.d.ts +0 -78
- package/build/types-ts3.8/metrics/webVitalSpans.d.ts +0 -65
- package/build/types-ts3.8/networkUtils.d.ts +0 -28
- package/build/types-ts3.8/types.d.ts +0 -15
- /package/build/cjs/{instrument → instrumentation}/dom.js +0 -0
- /package/build/cjs/{instrument → instrumentation}/history.js +0 -0
- /package/build/cjs/{instrument → instrumentation}/location.js +0 -0
- /package/build/cjs/{instrument → instrumentation}/xhr.js +0 -0
- /package/build/cjs/{metrics → performance}/resourceTiming.js +0 -0
- /package/build/esm/{instrument → instrumentation}/dom.js +0 -0
- /package/build/esm/{instrument → instrumentation}/history.js +0 -0
- /package/build/esm/{instrument → instrumentation}/location.js +0 -0
- /package/build/esm/{instrument → instrumentation}/xhr.js +0 -0
- /package/build/esm/{metrics → performance}/resourceTiming.js +0 -0
- /package/build/types/{instrument → instrumentation}/dom.d.ts +0 -0
- /package/build/types/{instrument → instrumentation}/history.d.ts +0 -0
- /package/build/types/{instrument → instrumentation}/location.d.ts +0 -0
- /package/build/types/{instrument → instrumentation}/xhr.d.ts +0 -0
- /package/build/types/{metrics → performance}/elementTiming.d.ts +0 -0
- /package/build/types/{metrics → performance}/resourceTiming.d.ts +0 -0
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
interface PerformanceEntryMap {
|
|
2
|
-
event: PerformanceEventTiming[];
|
|
3
|
-
'first-input': PerformanceEventTiming[];
|
|
4
|
-
'layout-shift': LayoutShift[];
|
|
5
|
-
'largest-contentful-paint': LargestContentfulPaint[];
|
|
6
|
-
'long-animation-frame': PerformanceLongAnimationFrameTiming[];
|
|
7
|
-
paint: PerformancePaintTiming[];
|
|
8
|
-
navigation: PerformanceNavigationTiming[];
|
|
9
|
-
resource: PerformanceResourceTiming[];
|
|
10
|
-
longtask: PerformanceEntry[];
|
|
11
|
-
element: PerformanceEntry[];
|
|
12
|
-
}
|
|
13
|
-
/**
|
|
14
|
-
* Takes a performance entry type and a callback function, and creates a
|
|
15
|
-
* `PerformanceObserver` instance that will observe the specified entry type
|
|
16
|
-
* with buffering enabled and call the callback _for each entry_.
|
|
17
|
-
*
|
|
18
|
-
* This function also feature-detects entry support and wraps the logic in a
|
|
19
|
-
* try/catch to avoid errors in unsupporting browsers.
|
|
20
|
-
*/
|
|
21
|
-
export declare const observe: <K extends keyof PerformanceEntryMap>(type: K, callback: (entries: PerformanceEntryMap[K]) => void, opts?: PerformanceObserverInit) => PerformanceObserver | undefined;
|
|
22
|
-
export {};
|
|
23
|
-
//# sourceMappingURL=observe.d.ts.map
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
export interface OnHiddenCallback {
|
|
2
|
-
(event: Event): void;
|
|
3
|
-
}
|
|
4
|
-
/**
|
|
5
|
-
* Sentry-specific change:
|
|
6
|
-
*
|
|
7
|
-
* This function's logic was NOT updated to web-vitals 4.2.4 or 5.x but we continue
|
|
8
|
-
* to use the web-vitals 3.5.2 version due to having stricter browser support.
|
|
9
|
-
*
|
|
10
|
-
* PR with context that made the changes:
|
|
11
|
-
* https://github.com/GoogleChrome/web-vitals/pull/442/files#r1530492402
|
|
12
|
-
*
|
|
13
|
-
* The PR removed listening to the `pagehide` event, in favour of only listening to
|
|
14
|
-
* the `visibilitychange` event. This is "more correct" but some browsers we still
|
|
15
|
-
* support (Safari <14.4) don't fully support `visibilitychange` or have known bugs
|
|
16
|
-
* with respect to the `visibilitychange` event.
|
|
17
|
-
*
|
|
18
|
-
* TODO (v11): If we decide to drop support for Safari 14.4, we can use the logic
|
|
19
|
-
* from web-vitals 4.2.4. In this case, we also need to update the integration tests
|
|
20
|
-
* that currently trigger the `pagehide` event to simulate the page being hidden.
|
|
21
|
-
*
|
|
22
|
-
* @param {OnHiddenCallback} cb - Callback to be executed when the page is hidden or unloaded.
|
|
23
|
-
*
|
|
24
|
-
* @deprecated use `whenIdleOrHidden` or `addPageListener('visibilitychange')` instead
|
|
25
|
-
*/
|
|
26
|
-
export declare const onHidden: (cb: OnHiddenCallback) => void;
|
|
27
|
-
//# sourceMappingURL=onHidden.d.ts.map
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
declare global {
|
|
2
|
-
interface Performance {
|
|
3
|
-
interactionCount: number;
|
|
4
|
-
}
|
|
5
|
-
}
|
|
6
|
-
/**
|
|
7
|
-
* Returns the `interactionCount` value using the native API (if available)
|
|
8
|
-
* or the polyfill estimate in this module.
|
|
9
|
-
*/
|
|
10
|
-
export declare const getInteractionCount: () => number;
|
|
11
|
-
/**
|
|
12
|
-
* Feature detects native support or initializes the polyfill if needed.
|
|
13
|
-
*/
|
|
14
|
-
export declare const initInteractionCountPolyfill: () => void;
|
|
15
|
-
//# sourceMappingURL=interactionCountPolyfill.d.ts.map
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { FCPMetric, MetricRatingThresholds, ReportOpts } from './types';
|
|
2
|
-
/** Thresholds for FCP. See https://web.dev/articles/fcp#what_is_a_good_fcp_score */
|
|
3
|
-
export declare const FCPThresholds: MetricRatingThresholds;
|
|
4
|
-
/**
|
|
5
|
-
* Calculates the [FCP](https://web.dev/articles/fcp) value for the current page and
|
|
6
|
-
* calls the `callback` function once the value is ready, along with the
|
|
7
|
-
* relevant `paint` performance entry used to determine the value. The reported
|
|
8
|
-
* value is a `DOMHighResTimeStamp`.
|
|
9
|
-
*/
|
|
10
|
-
export declare const onFCP: (onReport: (metric: FCPMetric) => void, opts?: ReportOpts) => void;
|
|
11
|
-
//# sourceMappingURL=onFCP.d.ts.map
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { MetricRatingThresholds, ReportOpts, TTFBMetric } from './types';
|
|
2
|
-
/** Thresholds for TTFB. See https://web.dev/articles/ttfb#what_is_a_good_ttfb_score */
|
|
3
|
-
export declare const TTFBThresholds: MetricRatingThresholds;
|
|
4
|
-
/**
|
|
5
|
-
* Calculates the [TTFB](https://web.dev/articles/ttfb) value for the
|
|
6
|
-
* current page and calls the `callback` function once the page has loaded,
|
|
7
|
-
* along with the relevant `navigation` performance entry used to determine the
|
|
8
|
-
* value. The reported value is a `DOMHighResTimeStamp`.
|
|
9
|
-
*
|
|
10
|
-
* Note, this function waits until after the page is loaded to call `callback`
|
|
11
|
-
* in order to ensure all properties of the `navigation` entry are populated.
|
|
12
|
-
* This is useful if you want to report on other metrics exposed by the
|
|
13
|
-
* [Navigation Timing API](https://w3c.github.io/navigation-timing/). For
|
|
14
|
-
* example, the TTFB metric starts from the page's [time
|
|
15
|
-
* origin](https://www.w3.org/TR/hr-time-2/#sec-time-origin), which means it
|
|
16
|
-
* includes time spent on DNS lookup, connection negotiation, network latency,
|
|
17
|
-
* and server processing time.
|
|
18
|
-
*/
|
|
19
|
-
export declare const onTTFB: (onReport: (metric: TTFBMetric) => void, opts?: ReportOpts) => void;
|
|
20
|
-
//# sourceMappingURL=onTTFB.d.ts.map
|
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
import { CLSMetric, CLSMetricWithAttribution } from './cls';
|
|
2
|
-
import { FCPMetric, FCPMetricWithAttribution } from './fcp';
|
|
3
|
-
import { INPMetric, INPMetricWithAttribution } from './inp';
|
|
4
|
-
import { LCPMetric, LCPMetricWithAttribution } from './lcp';
|
|
5
|
-
import { TTFBMetric, TTFBMetricWithAttribution } from './ttfb';
|
|
6
|
-
export interface Metric {
|
|
7
|
-
/**
|
|
8
|
-
* The name of the metric (in acronym form).
|
|
9
|
-
*/
|
|
10
|
-
name: 'CLS' | 'FCP' | 'INP' | 'LCP' | 'TTFB';
|
|
11
|
-
/**
|
|
12
|
-
* The current value of the metric.
|
|
13
|
-
*/
|
|
14
|
-
value: number;
|
|
15
|
-
/**
|
|
16
|
-
* The rating as to whether the metric value is within the "good",
|
|
17
|
-
* "needs improvement", or "poor" thresholds of the metric.
|
|
18
|
-
*/
|
|
19
|
-
rating: 'good' | 'needs-improvement' | 'poor';
|
|
20
|
-
/**
|
|
21
|
-
* The delta between the current value and the last-reported value.
|
|
22
|
-
* On the first report, `delta` and `value` will always be the same.
|
|
23
|
-
*/
|
|
24
|
-
delta: number;
|
|
25
|
-
/**
|
|
26
|
-
* A unique ID representing this particular metric instance. This ID can
|
|
27
|
-
* be used by an analytics tool to dedupe multiple values sent for the same
|
|
28
|
-
* metric instance, or to group multiple deltas together and calculate a
|
|
29
|
-
* total. It can also be used to differentiate multiple different metric
|
|
30
|
-
* instances sent from the same page, which can happen if the page is
|
|
31
|
-
* restored from the back/forward cache (in that case new metrics object
|
|
32
|
-
* get created).
|
|
33
|
-
*/
|
|
34
|
-
id: string;
|
|
35
|
-
/**
|
|
36
|
-
* Any performance entries relevant to the metric value calculation.
|
|
37
|
-
* The array may also be empty if the metric value was not based on any
|
|
38
|
-
* entries (e.g. a CLS value of 0 given no layout shifts).
|
|
39
|
-
*/
|
|
40
|
-
entries: PerformanceEntry[];
|
|
41
|
-
/**
|
|
42
|
-
* The type of navigation.
|
|
43
|
-
*
|
|
44
|
-
* This will be the value returned by the Navigation Timing API (or
|
|
45
|
-
* `undefined` if the browser doesn't support that API), with the following
|
|
46
|
-
* exceptions:
|
|
47
|
-
* - 'back-forward-cache': for pages that are restored from the bfcache.
|
|
48
|
-
* - 'back_forward' is renamed to 'back-forward' for consistency.
|
|
49
|
-
* - 'prerender': for pages that were prerendered.
|
|
50
|
-
* - 'restore': for pages that were discarded by the browser and then
|
|
51
|
-
* restored by the user.
|
|
52
|
-
*/
|
|
53
|
-
navigationType: 'navigate' | 'reload' | 'back-forward' | 'back-forward-cache' | 'prerender' | 'restore';
|
|
54
|
-
}
|
|
55
|
-
/** The union of supported metric types. */
|
|
56
|
-
export type MetricType = CLSMetric | FCPMetric | INPMetric | LCPMetric | TTFBMetric;
|
|
57
|
-
/** The union of supported metric attribution types. */
|
|
58
|
-
export type MetricWithAttribution = CLSMetricWithAttribution | FCPMetricWithAttribution | INPMetricWithAttribution | LCPMetricWithAttribution | TTFBMetricWithAttribution;
|
|
59
|
-
/**
|
|
60
|
-
* The thresholds of metric's "good", "needs improvement", and "poor" ratings.
|
|
61
|
-
*
|
|
62
|
-
* - Metric values up to and including [0] are rated "good"
|
|
63
|
-
* - Metric values up to and including [1] are rated "needs improvement"
|
|
64
|
-
* - Metric values above [1] are "poor"
|
|
65
|
-
*
|
|
66
|
-
* | Metric value | Rating |
|
|
67
|
-
* | --------------- | ------------------- |
|
|
68
|
-
* | ≦ [0] | "good" |
|
|
69
|
-
* | > [0] and ≦ [1] | "needs improvement" |
|
|
70
|
-
* | > [1] | "poor" |
|
|
71
|
-
*/
|
|
72
|
-
export type MetricRatingThresholds = [
|
|
73
|
-
number,
|
|
74
|
-
number
|
|
75
|
-
];
|
|
76
|
-
/**
|
|
77
|
-
* @deprecated Use metric-specific function types instead, such as:
|
|
78
|
-
* `(metric: LCPMetric) => void`. If a single callback type is needed for
|
|
79
|
-
* multiple metrics, use `(metric: MetricType) => void`.
|
|
80
|
-
*/
|
|
81
|
-
export interface ReportCallback {
|
|
82
|
-
(metric: MetricType): void;
|
|
83
|
-
}
|
|
84
|
-
export interface ReportOpts {
|
|
85
|
-
reportAllChanges?: boolean;
|
|
86
|
-
}
|
|
87
|
-
export interface AttributionReportOpts extends ReportOpts {
|
|
88
|
-
generateTarget?: (el: Node | null) => string | undefined;
|
|
89
|
-
}
|
|
90
|
-
/**
|
|
91
|
-
* The loading state of the document. Note: this value is similar to
|
|
92
|
-
* `document.readyState` but it subdivides the "interactive" state into the
|
|
93
|
-
* time before and after the DOMContentLoaded event fires.
|
|
94
|
-
*
|
|
95
|
-
* State descriptions:
|
|
96
|
-
* - `loading`: the initial document response has not yet been fully downloaded
|
|
97
|
-
* and parsed. This is equivalent to the corresponding `readyState` value.
|
|
98
|
-
* - `dom-interactive`: the document has been fully loaded and parsed, but
|
|
99
|
-
* scripts may not have yet finished loading and executing.
|
|
100
|
-
* - `dom-content-loaded`: the document is fully loaded and parsed, and all
|
|
101
|
-
* scripts (except `async` scripts) have loaded and finished executing.
|
|
102
|
-
* - `complete`: the document and all of its sub-resources have finished
|
|
103
|
-
* loading. This is equivalent to the corresponding `readyState` value.
|
|
104
|
-
*/
|
|
105
|
-
export type LoadState = 'loading' | 'dom-interactive' | 'dom-content-loaded' | 'complete';
|
|
106
|
-
//# sourceMappingURL=base.d.ts.map
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import { LoadState, Metric } from './base';
|
|
2
|
-
/**
|
|
3
|
-
* A CLS-specific version of the Metric object.
|
|
4
|
-
*/
|
|
5
|
-
export interface CLSMetric extends Metric {
|
|
6
|
-
name: 'CLS';
|
|
7
|
-
entries: LayoutShift[];
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* An object containing potentially-helpful debugging information that
|
|
11
|
-
* can be sent along with the CLS value for the current page visit in order
|
|
12
|
-
* to help identify issues happening to real-users in the field.
|
|
13
|
-
*/
|
|
14
|
-
export interface CLSAttribution {
|
|
15
|
-
/**
|
|
16
|
-
* By default, a selector identifying the first element (in document order)
|
|
17
|
-
* that shifted when the single largest layout shift that contributed to the
|
|
18
|
-
* page's CLS score occurred. If the `generateTarget` configuration option
|
|
19
|
-
* was passed, then this will instead be the return value of that function,
|
|
20
|
-
* falling back to the default if that returns null or undefined.
|
|
21
|
-
*/
|
|
22
|
-
largestShiftTarget?: string;
|
|
23
|
-
/**
|
|
24
|
-
* The time when the single largest layout shift contributing to the page's
|
|
25
|
-
* CLS score occurred.
|
|
26
|
-
*/
|
|
27
|
-
largestShiftTime?: DOMHighResTimeStamp;
|
|
28
|
-
/**
|
|
29
|
-
* The layout shift score of the single largest layout shift contributing to
|
|
30
|
-
* the page's CLS score.
|
|
31
|
-
*/
|
|
32
|
-
largestShiftValue?: number;
|
|
33
|
-
/**
|
|
34
|
-
* The `LayoutShiftEntry` representing the single largest layout shift
|
|
35
|
-
* contributing to the page's CLS score. (Useful when you need more than just
|
|
36
|
-
* `largestShiftTarget`, `largestShiftTime`, and `largestShiftValue`).
|
|
37
|
-
*/
|
|
38
|
-
largestShiftEntry?: LayoutShift;
|
|
39
|
-
/**
|
|
40
|
-
* The first element source (in document order) among the `sources` list
|
|
41
|
-
* of the `largestShiftEntry` object. (Also useful when you need more than
|
|
42
|
-
* just `largestShiftTarget`, `largestShiftTime`, and `largestShiftValue`).
|
|
43
|
-
*/
|
|
44
|
-
largestShiftSource?: LayoutShiftAttribution;
|
|
45
|
-
/**
|
|
46
|
-
* The loading state of the document at the time when the largest layout
|
|
47
|
-
* shift contribution to the page's CLS score occurred (see `LoadState`
|
|
48
|
-
* for details).
|
|
49
|
-
*/
|
|
50
|
-
loadState?: LoadState;
|
|
51
|
-
}
|
|
52
|
-
/**
|
|
53
|
-
* A CLS-specific version of the Metric object with attribution.
|
|
54
|
-
*/
|
|
55
|
-
export interface CLSMetricWithAttribution extends CLSMetric {
|
|
56
|
-
attribution: CLSAttribution;
|
|
57
|
-
}
|
|
58
|
-
//# sourceMappingURL=cls.d.ts.map
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { LoadState, Metric } from './base';
|
|
2
|
-
/**
|
|
3
|
-
* An FCP-specific version of the Metric object.
|
|
4
|
-
*/
|
|
5
|
-
export interface FCPMetric extends Metric {
|
|
6
|
-
name: 'FCP';
|
|
7
|
-
entries: PerformancePaintTiming[];
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* An object containing potentially-helpful debugging information that
|
|
11
|
-
* can be sent along with the FCP value for the current page visit in order
|
|
12
|
-
* to help identify issues happening to real-users in the field.
|
|
13
|
-
*/
|
|
14
|
-
export interface FCPAttribution {
|
|
15
|
-
/**
|
|
16
|
-
* The time from when the user initiates loading the page until when the
|
|
17
|
-
* browser receives the first byte of the response (a.k.a. TTFB).
|
|
18
|
-
*/
|
|
19
|
-
timeToFirstByte: number;
|
|
20
|
-
/**
|
|
21
|
-
* The delta between TTFB and the first contentful paint (FCP).
|
|
22
|
-
*/
|
|
23
|
-
firstByteToFCP: number;
|
|
24
|
-
/**
|
|
25
|
-
* The loading state of the document at the time when FCP `occurred (see
|
|
26
|
-
* `LoadState` for details). Ideally, documents can paint before they finish
|
|
27
|
-
* loading (e.g. the `loading` or `dom-interactive` phases).
|
|
28
|
-
*/
|
|
29
|
-
loadState: LoadState;
|
|
30
|
-
/**
|
|
31
|
-
* The `PerformancePaintTiming` entry corresponding to FCP.
|
|
32
|
-
*/
|
|
33
|
-
fcpEntry?: PerformancePaintTiming;
|
|
34
|
-
/**
|
|
35
|
-
* The `navigation` entry of the current page, which is useful for diagnosing
|
|
36
|
-
* general page load issues. This can be used to access `serverTiming` for example:
|
|
37
|
-
* navigationEntry?.serverTiming
|
|
38
|
-
*/
|
|
39
|
-
navigationEntry?: PerformanceNavigationTiming;
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* An FCP-specific version of the Metric object with attribution.
|
|
43
|
-
*/
|
|
44
|
-
export interface FCPMetricWithAttribution extends FCPMetric {
|
|
45
|
-
attribution: FCPAttribution;
|
|
46
|
-
}
|
|
47
|
-
//# sourceMappingURL=fcp.d.ts.map
|
|
@@ -1,150 +0,0 @@
|
|
|
1
|
-
import { AttributionReportOpts, LoadState, Metric, ReportOpts } from './base';
|
|
2
|
-
export interface INPReportOpts extends ReportOpts {
|
|
3
|
-
durationThreshold?: number;
|
|
4
|
-
}
|
|
5
|
-
export interface INPAttributionReportOpts extends AttributionReportOpts {
|
|
6
|
-
durationThreshold?: number;
|
|
7
|
-
}
|
|
8
|
-
/**
|
|
9
|
-
* An INP-specific version of the Metric object.
|
|
10
|
-
*/
|
|
11
|
-
export interface INPMetric extends Metric {
|
|
12
|
-
name: 'INP';
|
|
13
|
-
entries: PerformanceEventTiming[];
|
|
14
|
-
}
|
|
15
|
-
export interface INPLongestScriptSummary {
|
|
16
|
-
/**
|
|
17
|
-
* The longest Long Animation Frame script entry that intersects the INP
|
|
18
|
-
* interaction.
|
|
19
|
-
*/
|
|
20
|
-
entry: PerformanceScriptTiming;
|
|
21
|
-
/**
|
|
22
|
-
* The INP subpart where the longest script ran.
|
|
23
|
-
*/
|
|
24
|
-
subpart: 'input-delay' | 'processing-duration' | 'presentation-delay';
|
|
25
|
-
/**
|
|
26
|
-
* The amount of time the longest script intersected the INP duration.
|
|
27
|
-
*/
|
|
28
|
-
intersectingDuration: number;
|
|
29
|
-
}
|
|
30
|
-
/**
|
|
31
|
-
* An object containing potentially-helpful debugging information that
|
|
32
|
-
* can be sent along with the INP value for the current page visit in order
|
|
33
|
-
* to help identify issues happening to real-users in the field.
|
|
34
|
-
*/
|
|
35
|
-
export interface INPAttribution {
|
|
36
|
-
/**
|
|
37
|
-
* By default, a selector identifying the element that the user first
|
|
38
|
-
* interacted with as part of the frame where the INP candidate interaction
|
|
39
|
-
* occurred. If this value is an empty string, that generally means the
|
|
40
|
-
* element was removed from the DOM after the interaction. If the
|
|
41
|
-
* `generateTarget` configuration option was passed, then this will instead
|
|
42
|
-
* be the return value of that function, falling back to the default if that
|
|
43
|
-
* returns null or undefined.
|
|
44
|
-
*/
|
|
45
|
-
interactionTarget: string;
|
|
46
|
-
/**
|
|
47
|
-
* The time when the user first interacted during the frame where the INP
|
|
48
|
-
* candidate interaction occurred (if more than one interaction occurred
|
|
49
|
-
* within the frame, only the first time is reported).
|
|
50
|
-
*/
|
|
51
|
-
interactionTime: DOMHighResTimeStamp;
|
|
52
|
-
/**
|
|
53
|
-
* The type of interaction, based on the event type of the `event` entry
|
|
54
|
-
* that corresponds to the interaction (i.e. the first `event` entry
|
|
55
|
-
* containing an `interactionId` dispatched in a given animation frame).
|
|
56
|
-
* For "pointerdown", "pointerup", or "click" events this will be "pointer",
|
|
57
|
-
* and for "keydown" or "keyup" events this will be "keyboard".
|
|
58
|
-
*/
|
|
59
|
-
interactionType: 'pointer' | 'keyboard';
|
|
60
|
-
/**
|
|
61
|
-
* The best-guess timestamp of the next paint after the interaction.
|
|
62
|
-
* In general, this timestamp is the same as the `startTime + duration` of
|
|
63
|
-
* the event timing entry. However, since duration values are rounded to the
|
|
64
|
-
* nearest 8ms (and can be rounded down), this value is clamped to always be
|
|
65
|
-
* reported after the processing times.
|
|
66
|
-
*/
|
|
67
|
-
nextPaintTime: DOMHighResTimeStamp;
|
|
68
|
-
/**
|
|
69
|
-
* An array of Event Timing entries that were processed within the same
|
|
70
|
-
* animation frame as the INP candidate interaction.
|
|
71
|
-
*/
|
|
72
|
-
processedEventEntries: PerformanceEventTiming[];
|
|
73
|
-
/**
|
|
74
|
-
* The time from when the user interacted with the page until when the
|
|
75
|
-
* browser was first able to start processing event listeners for that
|
|
76
|
-
* interaction. This time captures the delay before event processing can
|
|
77
|
-
* begin due to the main thread being busy with other work.
|
|
78
|
-
*/
|
|
79
|
-
inputDelay: number;
|
|
80
|
-
/**
|
|
81
|
-
* The time from when the first event listener started running in response to
|
|
82
|
-
* the user interaction until when all event listener processing has finished.
|
|
83
|
-
*/
|
|
84
|
-
processingDuration: number;
|
|
85
|
-
/**
|
|
86
|
-
* The time from when the browser finished processing all event listeners for
|
|
87
|
-
* the user interaction until the next frame is presented on the screen and
|
|
88
|
-
* visible to the user. This time includes work on the main thread (such as
|
|
89
|
-
* `requestAnimationFrame()` callbacks, `ResizeObserver` and
|
|
90
|
-
* `IntersectionObserver` callbacks, and style/layout calculation) as well
|
|
91
|
-
* as off-main-thread work (such as compositor, GPU, and raster work).
|
|
92
|
-
*/
|
|
93
|
-
presentationDelay: number;
|
|
94
|
-
/**
|
|
95
|
-
* The loading state of the document at the time when the interaction
|
|
96
|
-
* corresponding to INP occurred (see `LoadState` for details). If the
|
|
97
|
-
* interaction occurred while the document was loading and executing script
|
|
98
|
-
* (e.g. usually in the `dom-interactive` phase) it can result in long delays.
|
|
99
|
-
*/
|
|
100
|
-
loadState: LoadState;
|
|
101
|
-
/**
|
|
102
|
-
* If the browser supports the Long Animation Frame API, this array will
|
|
103
|
-
* include any `long-animation-frame` entries that intersect with the INP
|
|
104
|
-
* candidate interaction's `startTime` and the `processingEnd` time of the
|
|
105
|
-
* last event processed within that animation frame. If the browser does not
|
|
106
|
-
* support the Long Animation Frame API or no `long-animation-frame` entries
|
|
107
|
-
* are detected, this array will be empty.
|
|
108
|
-
*/
|
|
109
|
-
longAnimationFrameEntries: PerformanceLongAnimationFrameTiming[];
|
|
110
|
-
/**
|
|
111
|
-
* Summary information about the longest script entry intersecting the INP
|
|
112
|
-
* duration. Note, only script entries above 5 milliseconds are reported by
|
|
113
|
-
* the Long Animation Frame API.
|
|
114
|
-
*/
|
|
115
|
-
longestScript?: INPLongestScriptSummary;
|
|
116
|
-
/**
|
|
117
|
-
* The total duration of Long Animation Frame scripts that intersect the INP
|
|
118
|
-
* duration excluding any forced style and layout (that is included in
|
|
119
|
-
* totalStyleAndLayout). Note, this is limited to scripts > 5 milliseconds.
|
|
120
|
-
*/
|
|
121
|
-
totalScriptDuration?: number;
|
|
122
|
-
/**
|
|
123
|
-
* The total style and layout duration from any Long Animation Frames
|
|
124
|
-
* intersecting the INP interaction. This includes any end-of-frame style and
|
|
125
|
-
* layout duration + any forced style and layout duration.
|
|
126
|
-
*/
|
|
127
|
-
totalStyleAndLayoutDuration?: number;
|
|
128
|
-
/**
|
|
129
|
-
* The off main-thread presentation delay from the end of the last Long
|
|
130
|
-
* Animation Frame (where available) until the INP end point.
|
|
131
|
-
*/
|
|
132
|
-
totalPaintDuration?: number;
|
|
133
|
-
/**
|
|
134
|
-
* The total unattributed time not included in any of the previous totals.
|
|
135
|
-
* This includes scripts < 5 milliseconds and other timings not attributed
|
|
136
|
-
* by Long Animation Frame (including when a frame is < 50ms and so has no
|
|
137
|
-
* Long Animation Frame).
|
|
138
|
-
* When no Long Animation Frames are present this will be undefined, rather
|
|
139
|
-
* than everything being unattributed to make it clearer when it's expected
|
|
140
|
-
* to be small.
|
|
141
|
-
*/
|
|
142
|
-
totalUnattributedDuration?: number;
|
|
143
|
-
}
|
|
144
|
-
/**
|
|
145
|
-
* An INP-specific version of the Metric object with attribution.
|
|
146
|
-
*/
|
|
147
|
-
export interface INPMetricWithAttribution extends INPMetric {
|
|
148
|
-
attribution: INPAttribution;
|
|
149
|
-
}
|
|
150
|
-
//# sourceMappingURL=inp.d.ts.map
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import { Metric } from './base.js';
|
|
2
|
-
/**
|
|
3
|
-
* An LCP-specific version of the Metric object.
|
|
4
|
-
*/
|
|
5
|
-
export interface LCPMetric extends Metric {
|
|
6
|
-
name: 'LCP';
|
|
7
|
-
entries: LargestContentfulPaint[];
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* An object containing potentially-helpful debugging information that
|
|
11
|
-
* can be sent along with the LCP value for the current page visit in order
|
|
12
|
-
* to help identify issues happening to real-users in the field.
|
|
13
|
-
*/
|
|
14
|
-
export interface LCPAttribution {
|
|
15
|
-
/**
|
|
16
|
-
* By default, a selector identifying the element corresponding to the
|
|
17
|
-
* largest contentful paint for the page. If the `generateTarget`
|
|
18
|
-
* configuration option was passed, then this will instead be the return
|
|
19
|
-
* value of that function, falling back to the default if that returns null
|
|
20
|
-
* or undefined.
|
|
21
|
-
*/
|
|
22
|
-
target?: string;
|
|
23
|
-
/**
|
|
24
|
-
* The URL (if applicable) of the LCP image resource. If the LCP element
|
|
25
|
-
* is a text node, this value will not be set.
|
|
26
|
-
*/
|
|
27
|
-
url?: string;
|
|
28
|
-
/**
|
|
29
|
-
* The time from when the user initiates loading the page until when the
|
|
30
|
-
* browser receives the first byte of the response (a.k.a. TTFB). See
|
|
31
|
-
* [Optimize LCP](https://web.dev/articles/optimize-lcp) for details.
|
|
32
|
-
*/
|
|
33
|
-
timeToFirstByte: number;
|
|
34
|
-
/**
|
|
35
|
-
* The delta between TTFB and when the browser starts loading the LCP
|
|
36
|
-
* resource (if there is one, otherwise 0). See [Optimize
|
|
37
|
-
* LCP](https://web.dev/articles/optimize-lcp) for details.
|
|
38
|
-
*/
|
|
39
|
-
resourceLoadDelay: number;
|
|
40
|
-
/**
|
|
41
|
-
* The total time it takes to load the LCP resource itself (if there is one,
|
|
42
|
-
* otherwise 0). See [Optimize LCP](https://web.dev/articles/optimize-lcp) for
|
|
43
|
-
* details.
|
|
44
|
-
*/
|
|
45
|
-
resourceLoadDuration: number;
|
|
46
|
-
/**
|
|
47
|
-
* The delta between when the LCP resource finishes loading until the LCP
|
|
48
|
-
* element is fully rendered. See [Optimize
|
|
49
|
-
* LCP](https://web.dev/articles/optimize-lcp) for details.
|
|
50
|
-
*/
|
|
51
|
-
elementRenderDelay: number;
|
|
52
|
-
/**
|
|
53
|
-
* The `navigation` entry of the current page, which is useful for diagnosing
|
|
54
|
-
* general page load issues. This can be used to access `serverTiming` for example:
|
|
55
|
-
* navigationEntry?.serverTiming
|
|
56
|
-
*/
|
|
57
|
-
navigationEntry?: PerformanceNavigationTiming;
|
|
58
|
-
/**
|
|
59
|
-
* The `resource` entry for the LCP resource (if applicable), which is useful
|
|
60
|
-
* for diagnosing resource load issues.
|
|
61
|
-
*/
|
|
62
|
-
lcpResourceEntry?: PerformanceResourceTiming;
|
|
63
|
-
/**
|
|
64
|
-
* The `LargestContentfulPaint` entry corresponding to LCP.
|
|
65
|
-
*/
|
|
66
|
-
lcpEntry?: LargestContentfulPaint;
|
|
67
|
-
}
|
|
68
|
-
/**
|
|
69
|
-
* An LCP-specific version of the Metric object with attribution.
|
|
70
|
-
*/
|
|
71
|
-
export interface LCPMetricWithAttribution extends LCPMetric {
|
|
72
|
-
attribution: LCPAttribution;
|
|
73
|
-
}
|
|
74
|
-
//# sourceMappingURL=lcp.d.ts.map
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { Metric } from './base';
|
|
2
|
-
/**
|
|
3
|
-
* A TTFB-specific version of the Metric object.
|
|
4
|
-
*/
|
|
5
|
-
export interface TTFBMetric extends Metric {
|
|
6
|
-
name: 'TTFB';
|
|
7
|
-
entries: PerformanceNavigationTiming[];
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* An object containing potentially-helpful debugging information that
|
|
11
|
-
* can be sent along with the TTFB value for the current page visit in order
|
|
12
|
-
* to help identify issues happening to real-users in the field.
|
|
13
|
-
*
|
|
14
|
-
* NOTE: these values are primarily useful for page loads not handled via
|
|
15
|
-
* service worker, as browsers differ in what they report when service worker
|
|
16
|
-
* is involved, see: https://github.com/w3c/navigation-timing/issues/199
|
|
17
|
-
*/
|
|
18
|
-
export interface TTFBAttribution {
|
|
19
|
-
/**
|
|
20
|
-
* The total time from when the user initiates loading the page to when the
|
|
21
|
-
* page starts to handle the request. Large values here are typically due
|
|
22
|
-
* to HTTP redirects, though other browser processing contributes to this
|
|
23
|
-
* duration as well (so even without redirect it's generally not zero).
|
|
24
|
-
*/
|
|
25
|
-
waitingDuration: number;
|
|
26
|
-
/**
|
|
27
|
-
* The total time spent checking the HTTP cache for a match. For navigations
|
|
28
|
-
* handled via service worker, this duration usually includes service worker
|
|
29
|
-
* start-up time as well as time processing `fetch` event listeners, with
|
|
30
|
-
* some exceptions, see: https://github.com/w3c/navigation-timing/issues/199
|
|
31
|
-
*/
|
|
32
|
-
cacheDuration: number;
|
|
33
|
-
/**
|
|
34
|
-
* The total time to resolve the DNS for the requested domain.
|
|
35
|
-
*/
|
|
36
|
-
dnsDuration: number;
|
|
37
|
-
/**
|
|
38
|
-
* The total time to create the connection to the requested domain.
|
|
39
|
-
*/
|
|
40
|
-
connectionDuration: number;
|
|
41
|
-
/**
|
|
42
|
-
* The total time from when the request was sent until the first byte of the
|
|
43
|
-
* response was received. This includes network time as well as server
|
|
44
|
-
* processing time.
|
|
45
|
-
*/
|
|
46
|
-
requestDuration: number;
|
|
47
|
-
/**
|
|
48
|
-
* The `navigation` entry of the current page, which is useful for diagnosing
|
|
49
|
-
* general page load issues. This can be used to access `serverTiming` for
|
|
50
|
-
* example: navigationEntry?.serverTiming
|
|
51
|
-
*/
|
|
52
|
-
navigationEntry?: PerformanceNavigationTiming;
|
|
53
|
-
}
|
|
54
|
-
/**
|
|
55
|
-
* A TTFB-specific version of the Metric object with attribution.
|
|
56
|
-
*/
|
|
57
|
-
export interface TTFBMetricWithAttribution extends TTFBMetric {
|
|
58
|
-
attribution: TTFBAttribution;
|
|
59
|
-
}
|
|
60
|
-
//# sourceMappingURL=ttfb.d.ts.map
|