@kubesense/kubesense-browser-rum-core 1.0.0
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/LICENSE +201 -0
- package/README.md +3 -0
- package/cjs/boot/preStartRum.d.ts +7 -0
- package/cjs/boot/preStartRum.js +190 -0
- package/cjs/boot/preStartRum.js.map +1 -0
- package/cjs/boot/rumPublicApi.d.ts +409 -0
- package/cjs/boot/rumPublicApi.js +168 -0
- package/cjs/boot/rumPublicApi.js.map +1 -0
- package/cjs/boot/startRum.d.ts +109 -0
- package/cjs/boot/startRum.js +153 -0
- package/cjs/boot/startRum.js.map +1 -0
- package/cjs/browser/cookieObservable.d.ts +8 -0
- package/cjs/browser/cookieObservable.js +39 -0
- package/cjs/browser/cookieObservable.js.map +1 -0
- package/cjs/browser/domMutationObservable.d.ts +27 -0
- package/cjs/browser/domMutationObservable.js +58 -0
- package/cjs/browser/domMutationObservable.js.map +1 -0
- package/cjs/browser/firstInputPolyfill.d.ts +8 -0
- package/cjs/browser/firstInputPolyfill.js +68 -0
- package/cjs/browser/firstInputPolyfill.js.map +1 -0
- package/cjs/browser/htmlDomUtils.d.ts +13 -0
- package/cjs/browser/htmlDomUtils.js +46 -0
- package/cjs/browser/htmlDomUtils.js.map +1 -0
- package/cjs/browser/locationChangeObservable.d.ts +7 -0
- package/cjs/browser/locationChangeObservable.js +51 -0
- package/cjs/browser/locationChangeObservable.js.map +1 -0
- package/cjs/browser/performanceObservable.d.ts +174 -0
- package/cjs/browser/performanceObservable.js +126 -0
- package/cjs/browser/performanceObservable.js.map +1 -0
- package/cjs/browser/performanceUtils.d.ts +7 -0
- package/cjs/browser/performanceUtils.js +42 -0
- package/cjs/browser/performanceUtils.js.map +1 -0
- package/cjs/browser/scroll.d.ts +2 -0
- package/cjs/browser/scroll.js +33 -0
- package/cjs/browser/scroll.js.map +1 -0
- package/cjs/browser/viewportObservable.d.ts +10 -0
- package/cjs/browser/viewportObservable.js +37 -0
- package/cjs/browser/viewportObservable.js.map +1 -0
- package/cjs/browser/windowOpenObservable.d.ts +5 -0
- package/cjs/browser/windowOpenObservable.js +10 -0
- package/cjs/browser/windowOpenObservable.js.map +1 -0
- package/cjs/domain/action/actionCollection.d.ts +21 -0
- package/cjs/domain/action/actionCollection.js +96 -0
- package/cjs/domain/action/actionCollection.js.map +1 -0
- package/cjs/domain/action/actionNameConstants.d.ts +18 -0
- package/cjs/domain/action/actionNameConstants.js +11 -0
- package/cjs/domain/action/actionNameConstants.js.map +1 -0
- package/cjs/domain/action/clickChain.d.ts +8 -0
- package/cjs/domain/action/clickChain.js +61 -0
- package/cjs/domain/action/clickChain.js.map +1 -0
- package/cjs/domain/action/computeFrustration.d.ts +6 -0
- package/cjs/domain/action/computeFrustration.js +70 -0
- package/cjs/domain/action/computeFrustration.js.map +1 -0
- package/cjs/domain/action/getActionNameFromElement.d.ts +4 -0
- package/cjs/domain/action/getActionNameFromElement.js +239 -0
- package/cjs/domain/action/getActionNameFromElement.js.map +1 -0
- package/cjs/domain/action/interactionSelectorCache.d.ts +5 -0
- package/cjs/domain/action/interactionSelectorCache.js +23 -0
- package/cjs/domain/action/interactionSelectorCache.js.map +1 -0
- package/cjs/domain/action/listenActionEvents.d.ts +19 -0
- package/cjs/domain/action/listenActionEvents.js +61 -0
- package/cjs/domain/action/listenActionEvents.js.map +1 -0
- package/cjs/domain/action/trackClickActions.d.ts +81 -0
- package/cjs/domain/action/trackClickActions.js +237 -0
- package/cjs/domain/action/trackClickActions.js.map +1 -0
- package/cjs/domain/assembly.d.ts +5 -0
- package/cjs/domain/assembly.js +102 -0
- package/cjs/domain/assembly.js.map +1 -0
- package/cjs/domain/configuration/configuration.d.ts +325 -0
- package/cjs/domain/configuration/configuration.js +205 -0
- package/cjs/domain/configuration/configuration.js.map +1 -0
- package/cjs/domain/configuration/index.d.ts +2 -0
- package/cjs/domain/configuration/index.js +19 -0
- package/cjs/domain/configuration/index.js.map +1 -0
- package/cjs/domain/configuration/jsonPathParser.d.ts +28 -0
- package/cjs/domain/configuration/jsonPathParser.js +159 -0
- package/cjs/domain/configuration/jsonPathParser.js.map +1 -0
- package/cjs/domain/configuration/remoteConfiguration.d.ts +39 -0
- package/cjs/domain/configuration/remoteConfiguration.js +243 -0
- package/cjs/domain/configuration/remoteConfiguration.js.map +1 -0
- package/cjs/domain/configuration/remoteConfiguration.types.d.ts +138 -0
- package/cjs/domain/configuration/remoteConfiguration.types.js +7 -0
- package/cjs/domain/configuration/remoteConfiguration.types.js.map +1 -0
- package/cjs/domain/contexts/ciVisibilityContext.d.ts +12 -0
- package/cjs/domain/contexts/ciVisibilityContext.js +34 -0
- package/cjs/domain/contexts/ciVisibilityContext.js.map +1 -0
- package/cjs/domain/contexts/connectivityContext.d.ts +2 -0
- package/cjs/domain/contexts/connectivityContext.js +11 -0
- package/cjs/domain/contexts/connectivityContext.js.map +1 -0
- package/cjs/domain/contexts/defaultContext.d.ts +4 -0
- package/cjs/domain/contexts/defaultContext.js +34 -0
- package/cjs/domain/contexts/defaultContext.js.map +1 -0
- package/cjs/domain/contexts/displayContext.d.ts +6 -0
- package/cjs/domain/contexts/displayContext.js +28 -0
- package/cjs/domain/contexts/displayContext.js.map +1 -0
- package/cjs/domain/contexts/featureFlagContext.d.ts +19 -0
- package/cjs/domain/contexts/featureFlagContext.js +53 -0
- package/cjs/domain/contexts/featureFlagContext.js.map +1 -0
- package/cjs/domain/contexts/internalContext.d.ts +12 -0
- package/cjs/domain/contexts/internalContext.js +26 -0
- package/cjs/domain/contexts/internalContext.js.map +1 -0
- package/cjs/domain/contexts/pageStateHistory.d.ts +23 -0
- package/cjs/domain/contexts/pageStateHistory.js +104 -0
- package/cjs/domain/contexts/pageStateHistory.js.map +1 -0
- package/cjs/domain/contexts/sessionContext.d.ts +5 -0
- package/cjs/domain/contexts/sessionContext.js +47 -0
- package/cjs/domain/contexts/sessionContext.js.map +1 -0
- package/cjs/domain/contexts/syntheticsContext.d.ts +2 -0
- package/cjs/domain/contexts/syntheticsContext.js +25 -0
- package/cjs/domain/contexts/syntheticsContext.js.map +1 -0
- package/cjs/domain/contexts/trackingConsentContext.d.ts +3 -0
- package/cjs/domain/contexts/trackingConsentContext.js +14 -0
- package/cjs/domain/contexts/trackingConsentContext.js.map +1 -0
- package/cjs/domain/contexts/urlContexts.d.ts +22 -0
- package/cjs/domain/contexts/urlContexts.js +64 -0
- package/cjs/domain/contexts/urlContexts.js.map +1 -0
- package/cjs/domain/contexts/userAgentDataContext.d.ts +2 -0
- package/cjs/domain/contexts/userAgentDataContext.js +31 -0
- package/cjs/domain/contexts/userAgentDataContext.js.map +1 -0
- package/cjs/domain/contexts/viewHistory.d.ts +17 -0
- package/cjs/domain/contexts/viewHistory.js +48 -0
- package/cjs/domain/contexts/viewHistory.js.map +1 -0
- package/cjs/domain/discardNegativeDuration.d.ts +2 -0
- package/cjs/domain/discardNegativeDuration.js +8 -0
- package/cjs/domain/discardNegativeDuration.js.map +1 -0
- package/cjs/domain/error/errorCollection.d.ts +17 -0
- package/cjs/domain/error/errorCollection.js +74 -0
- package/cjs/domain/error/errorCollection.js.map +1 -0
- package/cjs/domain/error/trackConsoleError.d.ts +4 -0
- package/cjs/domain/error/trackConsoleError.js +13 -0
- package/cjs/domain/error/trackConsoleError.js.map +1 -0
- package/cjs/domain/error/trackReportError.d.ts +5 -0
- package/cjs/domain/error/trackReportError.js +16 -0
- package/cjs/domain/error/trackReportError.js.map +1 -0
- package/cjs/domain/event/eventCollection.d.ts +10 -0
- package/cjs/domain/event/eventCollection.js +27 -0
- package/cjs/domain/event/eventCollection.js.map +1 -0
- package/cjs/domain/getSelectorFromElement.d.ts +64 -0
- package/cjs/domain/getSelectorFromElement.js +218 -0
- package/cjs/domain/getSelectorFromElement.js.map +1 -0
- package/cjs/domain/getSessionReplayUrl.d.ts +9 -0
- package/cjs/domain/getSessionReplayUrl.js +34 -0
- package/cjs/domain/getSessionReplayUrl.js.map +1 -0
- package/cjs/domain/hooks.d.ts +23 -0
- package/cjs/domain/hooks.js +6 -0
- package/cjs/domain/hooks.js.map +1 -0
- package/cjs/domain/lifeCycle.d.ts +73 -0
- package/cjs/domain/lifeCycle.js +6 -0
- package/cjs/domain/lifeCycle.js.map +1 -0
- package/cjs/domain/limitModification.d.ts +8 -0
- package/cjs/domain/limitModification.js +46 -0
- package/cjs/domain/limitModification.js.map +1 -0
- package/cjs/domain/longTask/longTaskCollection.d.ts +18 -0
- package/cjs/domain/longTask/longTaskCollection.js +91 -0
- package/cjs/domain/longTask/longTaskCollection.js.map +1 -0
- package/cjs/domain/plugins.d.ts +40 -0
- package/cjs/domain/plugins.js +15 -0
- package/cjs/domain/plugins.js.map +1 -0
- package/cjs/domain/privacy.d.ts +44 -0
- package/cjs/domain/privacy.js +313 -0
- package/cjs/domain/privacy.js.map +1 -0
- package/cjs/domain/privacyConstants.d.ts +23 -0
- package/cjs/domain/privacyConstants.js +39 -0
- package/cjs/domain/privacyConstants.js.map +1 -0
- package/cjs/domain/requestCollection.d.ts +54 -0
- package/cjs/domain/requestCollection.js +111 -0
- package/cjs/domain/requestCollection.js.map +1 -0
- package/cjs/domain/resource/graphql.d.ts +23 -0
- package/cjs/domain/resource/graphql.js +97 -0
- package/cjs/domain/resource/graphql.js.map +1 -0
- package/cjs/domain/resource/matchRequestResourceEntry.d.ts +16 -0
- package/cjs/domain/resource/matchRequestResourceEntry.js +49 -0
- package/cjs/domain/resource/matchRequestResourceEntry.js.map +1 -0
- package/cjs/domain/resource/requestRegistry.d.ts +9 -0
- package/cjs/domain/resource/requestRegistry.js +41 -0
- package/cjs/domain/resource/requestRegistry.js.map +1 -0
- package/cjs/domain/resource/resourceCollection.d.ts +7 -0
- package/cjs/domain/resource/resourceCollection.js +190 -0
- package/cjs/domain/resource/resourceCollection.js.map +1 -0
- package/cjs/domain/resource/resourceUtils.d.ts +55 -0
- package/cjs/domain/resource/resourceUtils.js +259 -0
- package/cjs/domain/resource/resourceUtils.js.map +1 -0
- package/cjs/domain/resource/retrieveInitialDocumentResourceTiming.d.ts +4 -0
- package/cjs/domain/resource/retrieveInitialDocumentResourceTiming.js +24 -0
- package/cjs/domain/resource/retrieveInitialDocumentResourceTiming.js.map +1 -0
- package/cjs/domain/rumSessionManager.d.ts +36 -0
- package/cjs/domain/rumSessionManager.js +77 -0
- package/cjs/domain/rumSessionManager.js.map +1 -0
- package/cjs/domain/sampler/sampler.d.ts +10 -0
- package/cjs/domain/sampler/sampler.js +63 -0
- package/cjs/domain/sampler/sampler.js.map +1 -0
- package/cjs/domain/startCustomerDataTelemetry.d.ts +4 -0
- package/cjs/domain/startCustomerDataTelemetry.js +56 -0
- package/cjs/domain/startCustomerDataTelemetry.js.map +1 -0
- package/cjs/domain/tracing/getDocumentTraceId.d.ts +12 -0
- package/cjs/domain/tracing/getDocumentTraceId.js +76 -0
- package/cjs/domain/tracing/getDocumentTraceId.js.map +1 -0
- package/cjs/domain/tracing/identifier.d.ts +13 -0
- package/cjs/domain/tracing/identifier.js +55 -0
- package/cjs/domain/tracing/identifier.js.map +1 -0
- package/cjs/domain/tracing/sampler.d.ts +10 -0
- package/cjs/domain/tracing/sampler.js +69 -0
- package/cjs/domain/tracing/sampler.js.map +1 -0
- package/cjs/domain/tracing/tracer.d.ts +30 -0
- package/cjs/domain/tracing/tracer.js +161 -0
- package/cjs/domain/tracing/tracer.js.map +1 -0
- package/cjs/domain/tracing/tracer.types.d.ts +12 -0
- package/cjs/domain/tracing/tracer.types.js +3 -0
- package/cjs/domain/tracing/tracer.types.js.map +1 -0
- package/cjs/domain/trackEventCounts.d.ts +17 -0
- package/cjs/domain/trackEventCounts.js +50 -0
- package/cjs/domain/trackEventCounts.js.map +1 -0
- package/cjs/domain/view/bfCacheSupport.d.ts +2 -0
- package/cjs/domain/view/bfCacheSupport.js +13 -0
- package/cjs/domain/view/bfCacheSupport.js.map +1 -0
- package/cjs/domain/view/trackViewEventCounts.d.ts +5 -0
- package/cjs/domain/view/trackViewEventCounts.js +16 -0
- package/cjs/domain/view/trackViewEventCounts.js.map +1 -0
- package/cjs/domain/view/trackViews.d.ts +65 -0
- package/cjs/domain/view/trackViews.js +275 -0
- package/cjs/domain/view/trackViews.js.map +1 -0
- package/cjs/domain/view/viewCollection.d.ts +18 -0
- package/cjs/domain/view/viewCollection.js +153 -0
- package/cjs/domain/view/viewCollection.js.map +1 -0
- package/cjs/domain/view/viewMetrics/getClsAttributionImpactedArea.d.ts +6 -0
- package/cjs/domain/view/viewMetrics/getClsAttributionImpactedArea.js +32 -0
- package/cjs/domain/view/viewMetrics/getClsAttributionImpactedArea.js.map +1 -0
- package/cjs/domain/view/viewMetrics/interactionCountPolyfill.d.ts +18 -0
- package/cjs/domain/view/viewMetrics/interactionCountPolyfill.js +44 -0
- package/cjs/domain/view/viewMetrics/interactionCountPolyfill.js.map +1 -0
- package/cjs/domain/view/viewMetrics/startInitialViewMetricsTelemetry.d.ts +6 -0
- package/cjs/domain/view/viewMetrics/startInitialViewMetricsTelemetry.js +44 -0
- package/cjs/domain/view/viewMetrics/startInitialViewMetricsTelemetry.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackBfcacheMetrics.d.ts +8 -0
- package/cjs/domain/view/viewMetrics/trackBfcacheMetrics.js +17 -0
- package/cjs/domain/view/viewMetrics/trackBfcacheMetrics.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackCommonViewMetrics.d.ts +21 -0
- package/cjs/domain/view/viewMetrics/trackCommonViewMetrics.js +37 -0
- package/cjs/domain/view/viewMetrics/trackCommonViewMetrics.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackCumulativeLayoutShift.d.ts +37 -0
- package/cjs/domain/view/viewMetrics/trackCumulativeLayoutShift.js +135 -0
- package/cjs/domain/view/viewMetrics/trackCumulativeLayoutShift.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackFirstContentfulPaint.d.ts +13 -0
- package/cjs/domain/view/viewMetrics/trackFirstContentfulPaint.js +39 -0
- package/cjs/domain/view/viewMetrics/trackFirstContentfulPaint.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackFirstHidden.d.ts +10 -0
- package/cjs/domain/view/viewMetrics/trackFirstHidden.js +33 -0
- package/cjs/domain/view/viewMetrics/trackFirstHidden.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackFirstInput.d.ts +19 -0
- package/cjs/domain/view/viewMetrics/trackFirstInput.js +43 -0
- package/cjs/domain/view/viewMetrics/trackFirstInput.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackInitialViewMetrics.d.ts +15 -0
- package/cjs/domain/view/viewMetrics/trackInitialViewMetrics.js +41 -0
- package/cjs/domain/view/viewMetrics/trackInitialViewMetrics.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackInteractionToNextPaint.d.ts +25 -0
- package/cjs/domain/view/viewMetrics/trackInteractionToNextPaint.js +155 -0
- package/cjs/domain/view/viewMetrics/trackInteractionToNextPaint.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackLargestContentfulPaint.d.ts +18 -0
- package/cjs/domain/view/viewMetrics/trackLargestContentfulPaint.js +61 -0
- package/cjs/domain/view/viewMetrics/trackLargestContentfulPaint.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackLoadingTime.d.ts +14 -0
- package/cjs/domain/view/viewMetrics/trackLoadingTime.js +50 -0
- package/cjs/domain/view/viewMetrics/trackLoadingTime.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackNavigationTimings.d.ts +14 -0
- package/cjs/domain/view/viewMetrics/trackNavigationTimings.js +43 -0
- package/cjs/domain/view/viewMetrics/trackNavigationTimings.js.map +1 -0
- package/cjs/domain/view/viewMetrics/trackScrollMetrics.d.ts +25 -0
- package/cjs/domain/view/viewMetrics/trackScrollMetrics.js +78 -0
- package/cjs/domain/view/viewMetrics/trackScrollMetrics.js.map +1 -0
- package/cjs/domain/vital/vitalCollection.d.ts +55 -0
- package/cjs/domain/vital/vitalCollection.js +113 -0
- package/cjs/domain/vital/vitalCollection.js.map +1 -0
- package/cjs/domain/waitPageActivityEnd.d.ts +54 -0
- package/cjs/domain/waitPageActivityEnd.js +129 -0
- package/cjs/domain/waitPageActivityEnd.js.map +1 -0
- package/cjs/domainContext.types.d.ts +39 -0
- package/cjs/domainContext.types.js +6 -0
- package/cjs/domainContext.types.js.map +1 -0
- package/cjs/index.d.ts +41 -0
- package/cjs/index.js +59 -0
- package/cjs/index.js.map +1 -0
- package/cjs/rawRumEvent.types.d.ts +326 -0
- package/cjs/rawRumEvent.types.js +34 -0
- package/cjs/rawRumEvent.types.js.map +1 -0
- package/cjs/rumEvent.types.d.ts +2026 -0
- package/cjs/rumEvent.types.js +7 -0
- package/cjs/rumEvent.types.js.map +1 -0
- package/cjs/transport/formDataTransport.d.ts +16 -0
- package/cjs/transport/formDataTransport.js +46 -0
- package/cjs/transport/formDataTransport.js.map +1 -0
- package/cjs/transport/startRumBatch.d.ts +5 -0
- package/cjs/transport/startRumBatch.js +33 -0
- package/cjs/transport/startRumBatch.js.map +1 -0
- package/cjs/transport/startRumEventBridge.d.ts +2 -0
- package/cjs/transport/startRumEventBridge.js +11 -0
- package/cjs/transport/startRumEventBridge.js.map +1 -0
- package/esm/boot/preStartRum.d.ts +7 -0
- package/esm/boot/preStartRum.js +187 -0
- package/esm/boot/preStartRum.js.map +1 -0
- package/esm/boot/rumPublicApi.d.ts +409 -0
- package/esm/boot/rumPublicApi.js +165 -0
- package/esm/boot/rumPublicApi.js.map +1 -0
- package/esm/boot/startRum.d.ts +109 -0
- package/esm/boot/startRum.js +149 -0
- package/esm/boot/startRum.js.map +1 -0
- package/esm/browser/cookieObservable.d.ts +8 -0
- package/esm/browser/cookieObservable.js +35 -0
- package/esm/browser/cookieObservable.js.map +1 -0
- package/esm/browser/domMutationObservable.d.ts +27 -0
- package/esm/browser/domMutationObservable.js +54 -0
- package/esm/browser/domMutationObservable.js.map +1 -0
- package/esm/browser/firstInputPolyfill.d.ts +8 -0
- package/esm/browser/firstInputPolyfill.js +65 -0
- package/esm/browser/firstInputPolyfill.js.map +1 -0
- package/esm/browser/htmlDomUtils.d.ts +13 -0
- package/esm/browser/htmlDomUtils.js +36 -0
- package/esm/browser/htmlDomUtils.js.map +1 -0
- package/esm/browser/locationChangeObservable.d.ts +7 -0
- package/esm/browser/locationChangeObservable.js +48 -0
- package/esm/browser/locationChangeObservable.js.map +1 -0
- package/esm/browser/performanceObservable.d.ts +174 -0
- package/esm/browser/performanceObservable.js +121 -0
- package/esm/browser/performanceObservable.js.map +1 -0
- package/esm/browser/performanceUtils.d.ts +7 -0
- package/esm/browser/performanceUtils.js +38 -0
- package/esm/browser/performanceUtils.js.map +1 -0
- package/esm/browser/scroll.d.ts +2 -0
- package/esm/browser/scroll.js +29 -0
- package/esm/browser/scroll.js.map +1 -0
- package/esm/browser/viewportObservable.d.ts +10 -0
- package/esm/browser/viewportObservable.js +32 -0
- package/esm/browser/viewportObservable.js.map +1 -0
- package/esm/browser/windowOpenObservable.d.ts +5 -0
- package/esm/browser/windowOpenObservable.js +7 -0
- package/esm/browser/windowOpenObservable.js.map +1 -0
- package/esm/domain/action/actionCollection.d.ts +21 -0
- package/esm/domain/action/actionCollection.js +93 -0
- package/esm/domain/action/actionCollection.js.map +1 -0
- package/esm/domain/action/actionNameConstants.d.ts +18 -0
- package/esm/domain/action/actionNameConstants.js +8 -0
- package/esm/domain/action/actionNameConstants.js.map +1 -0
- package/esm/domain/action/clickChain.d.ts +8 -0
- package/esm/domain/action/clickChain.js +57 -0
- package/esm/domain/action/clickChain.js.map +1 -0
- package/esm/domain/action/computeFrustration.d.ts +6 -0
- package/esm/domain/action/computeFrustration.js +65 -0
- package/esm/domain/action/computeFrustration.js.map +1 -0
- package/esm/domain/action/getActionNameFromElement.d.ts +4 -0
- package/esm/domain/action/getActionNameFromElement.js +236 -0
- package/esm/domain/action/getActionNameFromElement.js.map +1 -0
- package/esm/domain/action/interactionSelectorCache.d.ts +5 -0
- package/esm/domain/action/interactionSelectorCache.js +18 -0
- package/esm/domain/action/interactionSelectorCache.js.map +1 -0
- package/esm/domain/action/listenActionEvents.d.ts +19 -0
- package/esm/domain/action/listenActionEvents.js +58 -0
- package/esm/domain/action/listenActionEvents.js.map +1 -0
- package/esm/domain/action/trackClickActions.d.ts +81 -0
- package/esm/domain/action/trackClickActions.js +232 -0
- package/esm/domain/action/trackClickActions.js.map +1 -0
- package/esm/domain/assembly.d.ts +5 -0
- package/esm/domain/assembly.js +99 -0
- package/esm/domain/assembly.js.map +1 -0
- package/esm/domain/configuration/configuration.d.ts +325 -0
- package/esm/domain/configuration/configuration.js +200 -0
- package/esm/domain/configuration/configuration.js.map +1 -0
- package/esm/domain/configuration/index.d.ts +2 -0
- package/esm/domain/configuration/index.js +3 -0
- package/esm/domain/configuration/index.js.map +1 -0
- package/esm/domain/configuration/jsonPathParser.d.ts +28 -0
- package/esm/domain/configuration/jsonPathParser.js +156 -0
- package/esm/domain/configuration/jsonPathParser.js.map +1 -0
- package/esm/domain/configuration/remoteConfiguration.d.ts +39 -0
- package/esm/domain/configuration/remoteConfiguration.js +236 -0
- package/esm/domain/configuration/remoteConfiguration.js.map +1 -0
- package/esm/domain/configuration/remoteConfiguration.types.d.ts +138 -0
- package/esm/domain/configuration/remoteConfiguration.types.js +6 -0
- package/esm/domain/configuration/remoteConfiguration.types.js.map +1 -0
- package/esm/domain/contexts/ciVisibilityContext.d.ts +12 -0
- package/esm/domain/contexts/ciVisibilityContext.js +30 -0
- package/esm/domain/contexts/ciVisibilityContext.js.map +1 -0
- package/esm/domain/contexts/connectivityContext.d.ts +2 -0
- package/esm/domain/contexts/connectivityContext.js +8 -0
- package/esm/domain/contexts/connectivityContext.js.map +1 -0
- package/esm/domain/contexts/defaultContext.d.ts +4 -0
- package/esm/domain/contexts/defaultContext.js +31 -0
- package/esm/domain/contexts/defaultContext.js.map +1 -0
- package/esm/domain/contexts/displayContext.d.ts +6 -0
- package/esm/domain/contexts/displayContext.js +25 -0
- package/esm/domain/contexts/displayContext.js.map +1 -0
- package/esm/domain/contexts/featureFlagContext.d.ts +19 -0
- package/esm/domain/contexts/featureFlagContext.js +49 -0
- package/esm/domain/contexts/featureFlagContext.js.map +1 -0
- package/esm/domain/contexts/internalContext.d.ts +12 -0
- package/esm/domain/contexts/internalContext.js +23 -0
- package/esm/domain/contexts/internalContext.js.map +1 -0
- package/esm/domain/contexts/pageStateHistory.d.ts +23 -0
- package/esm/domain/contexts/pageStateHistory.js +100 -0
- package/esm/domain/contexts/pageStateHistory.js.map +1 -0
- package/esm/domain/contexts/sessionContext.d.ts +5 -0
- package/esm/domain/contexts/sessionContext.js +44 -0
- package/esm/domain/contexts/sessionContext.js.map +1 -0
- package/esm/domain/contexts/syntheticsContext.d.ts +2 -0
- package/esm/domain/contexts/syntheticsContext.js +22 -0
- package/esm/domain/contexts/syntheticsContext.js.map +1 -0
- package/esm/domain/contexts/trackingConsentContext.d.ts +3 -0
- package/esm/domain/contexts/trackingConsentContext.js +11 -0
- package/esm/domain/contexts/trackingConsentContext.js.map +1 -0
- package/esm/domain/contexts/urlContexts.d.ts +22 -0
- package/esm/domain/contexts/urlContexts.js +60 -0
- package/esm/domain/contexts/urlContexts.js.map +1 -0
- package/esm/domain/contexts/userAgentDataContext.d.ts +2 -0
- package/esm/domain/contexts/userAgentDataContext.js +28 -0
- package/esm/domain/contexts/userAgentDataContext.js.map +1 -0
- package/esm/domain/contexts/viewHistory.d.ts +17 -0
- package/esm/domain/contexts/viewHistory.js +44 -0
- package/esm/domain/contexts/viewHistory.js.map +1 -0
- package/esm/domain/discardNegativeDuration.d.ts +2 -0
- package/esm/domain/discardNegativeDuration.js +5 -0
- package/esm/domain/discardNegativeDuration.js.map +1 -0
- package/esm/domain/error/errorCollection.d.ts +17 -0
- package/esm/domain/error/errorCollection.js +70 -0
- package/esm/domain/error/errorCollection.js.map +1 -0
- package/esm/domain/error/trackConsoleError.d.ts +4 -0
- package/esm/domain/error/trackConsoleError.js +10 -0
- package/esm/domain/error/trackConsoleError.js.map +1 -0
- package/esm/domain/error/trackReportError.d.ts +5 -0
- package/esm/domain/error/trackReportError.js +13 -0
- package/esm/domain/error/trackReportError.js.map +1 -0
- package/esm/domain/event/eventCollection.d.ts +10 -0
- package/esm/domain/event/eventCollection.js +24 -0
- package/esm/domain/event/eventCollection.js.map +1 -0
- package/esm/domain/getSelectorFromElement.d.ts +64 -0
- package/esm/domain/getSelectorFromElement.js +213 -0
- package/esm/domain/getSelectorFromElement.js.map +1 -0
- package/esm/domain/getSessionReplayUrl.d.ts +9 -0
- package/esm/domain/getSessionReplayUrl.js +30 -0
- package/esm/domain/getSessionReplayUrl.js.map +1 -0
- package/esm/domain/hooks.d.ts +23 -0
- package/esm/domain/hooks.js +3 -0
- package/esm/domain/hooks.js.map +1 -0
- package/esm/domain/lifeCycle.d.ts +73 -0
- package/esm/domain/lifeCycle.js +3 -0
- package/esm/domain/lifeCycle.js.map +1 -0
- package/esm/domain/limitModification.d.ts +8 -0
- package/esm/domain/limitModification.js +43 -0
- package/esm/domain/limitModification.js.map +1 -0
- package/esm/domain/longTask/longTaskCollection.d.ts +18 -0
- package/esm/domain/longTask/longTaskCollection.js +87 -0
- package/esm/domain/longTask/longTaskCollection.js.map +1 -0
- package/esm/domain/plugins.d.ts +40 -0
- package/esm/domain/plugins.js +12 -0
- package/esm/domain/plugins.js.map +1 -0
- package/esm/domain/privacy.d.ts +44 -0
- package/esm/domain/privacy.js +302 -0
- package/esm/domain/privacy.js.map +1 -0
- package/esm/domain/privacyConstants.d.ts +23 -0
- package/esm/domain/privacyConstants.js +35 -0
- package/esm/domain/privacyConstants.js.map +1 -0
- package/esm/domain/requestCollection.d.ts +54 -0
- package/esm/domain/requestCollection.js +106 -0
- package/esm/domain/requestCollection.js.map +1 -0
- package/esm/domain/resource/graphql.d.ts +23 -0
- package/esm/domain/resource/graphql.js +91 -0
- package/esm/domain/resource/graphql.js.map +1 -0
- package/esm/domain/resource/matchRequestResourceEntry.d.ts +16 -0
- package/esm/domain/resource/matchRequestResourceEntry.js +46 -0
- package/esm/domain/resource/matchRequestResourceEntry.js.map +1 -0
- package/esm/domain/resource/requestRegistry.d.ts +9 -0
- package/esm/domain/resource/requestRegistry.js +37 -0
- package/esm/domain/resource/requestRegistry.js.map +1 -0
- package/esm/domain/resource/resourceCollection.d.ts +7 -0
- package/esm/domain/resource/resourceCollection.js +187 -0
- package/esm/domain/resource/resourceCollection.js.map +1 -0
- package/esm/domain/resource/resourceUtils.d.ts +55 -0
- package/esm/domain/resource/resourceUtils.js +244 -0
- package/esm/domain/resource/resourceUtils.js.map +1 -0
- package/esm/domain/resource/retrieveInitialDocumentResourceTiming.d.ts +4 -0
- package/esm/domain/resource/retrieveInitialDocumentResourceTiming.js +21 -0
- package/esm/domain/resource/retrieveInitialDocumentResourceTiming.js.map +1 -0
- package/esm/domain/rumSessionManager.d.ts +36 -0
- package/esm/domain/rumSessionManager.js +72 -0
- package/esm/domain/rumSessionManager.js.map +1 -0
- package/esm/domain/sampler/sampler.d.ts +10 -0
- package/esm/domain/sampler/sampler.js +58 -0
- package/esm/domain/sampler/sampler.js.map +1 -0
- package/esm/domain/startCustomerDataTelemetry.d.ts +4 -0
- package/esm/domain/startCustomerDataTelemetry.js +52 -0
- package/esm/domain/startCustomerDataTelemetry.js.map +1 -0
- package/esm/domain/tracing/getDocumentTraceId.d.ts +12 -0
- package/esm/domain/tracing/getDocumentTraceId.js +68 -0
- package/esm/domain/tracing/getDocumentTraceId.js.map +1 -0
- package/esm/domain/tracing/identifier.d.ts +13 -0
- package/esm/domain/tracing/identifier.js +50 -0
- package/esm/domain/tracing/identifier.js.map +1 -0
- package/esm/domain/tracing/sampler.d.ts +10 -0
- package/esm/domain/tracing/sampler.js +64 -0
- package/esm/domain/tracing/sampler.js.map +1 -0
- package/esm/domain/tracing/tracer.d.ts +30 -0
- package/esm/domain/tracing/tracer.js +156 -0
- package/esm/domain/tracing/tracer.js.map +1 -0
- package/esm/domain/tracing/tracer.types.d.ts +12 -0
- package/esm/domain/tracing/tracer.types.js +2 -0
- package/esm/domain/tracing/tracer.types.js.map +1 -0
- package/esm/domain/trackEventCounts.d.ts +17 -0
- package/esm/domain/trackEventCounts.js +47 -0
- package/esm/domain/trackEventCounts.js.map +1 -0
- package/esm/domain/view/bfCacheSupport.d.ts +2 -0
- package/esm/domain/view/bfCacheSupport.js +10 -0
- package/esm/domain/view/bfCacheSupport.js.map +1 -0
- package/esm/domain/view/trackViewEventCounts.d.ts +5 -0
- package/esm/domain/view/trackViewEventCounts.js +13 -0
- package/esm/domain/view/trackViewEventCounts.js.map +1 -0
- package/esm/domain/view/trackViews.d.ts +65 -0
- package/esm/domain/view/trackViews.js +271 -0
- package/esm/domain/view/trackViews.js.map +1 -0
- package/esm/domain/view/viewCollection.d.ts +18 -0
- package/esm/domain/view/viewCollection.js +150 -0
- package/esm/domain/view/viewCollection.js.map +1 -0
- package/esm/domain/view/viewMetrics/getClsAttributionImpactedArea.d.ts +6 -0
- package/esm/domain/view/viewMetrics/getClsAttributionImpactedArea.js +28 -0
- package/esm/domain/view/viewMetrics/getClsAttributionImpactedArea.js.map +1 -0
- package/esm/domain/view/viewMetrics/interactionCountPolyfill.d.ts +18 -0
- package/esm/domain/view/viewMetrics/interactionCountPolyfill.js +39 -0
- package/esm/domain/view/viewMetrics/interactionCountPolyfill.js.map +1 -0
- package/esm/domain/view/viewMetrics/startInitialViewMetricsTelemetry.d.ts +6 -0
- package/esm/domain/view/viewMetrics/startInitialViewMetricsTelemetry.js +41 -0
- package/esm/domain/view/viewMetrics/startInitialViewMetricsTelemetry.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackBfcacheMetrics.d.ts +8 -0
- package/esm/domain/view/viewMetrics/trackBfcacheMetrics.js +14 -0
- package/esm/domain/view/viewMetrics/trackBfcacheMetrics.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackCommonViewMetrics.d.ts +21 -0
- package/esm/domain/view/viewMetrics/trackCommonViewMetrics.js +34 -0
- package/esm/domain/view/viewMetrics/trackCommonViewMetrics.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackCumulativeLayoutShift.d.ts +37 -0
- package/esm/domain/view/viewMetrics/trackCumulativeLayoutShift.js +130 -0
- package/esm/domain/view/viewMetrics/trackCumulativeLayoutShift.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackFirstContentfulPaint.d.ts +13 -0
- package/esm/domain/view/viewMetrics/trackFirstContentfulPaint.js +34 -0
- package/esm/domain/view/viewMetrics/trackFirstContentfulPaint.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackFirstHidden.d.ts +10 -0
- package/esm/domain/view/viewMetrics/trackFirstHidden.js +30 -0
- package/esm/domain/view/viewMetrics/trackFirstHidden.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackFirstInput.d.ts +19 -0
- package/esm/domain/view/viewMetrics/trackFirstInput.js +40 -0
- package/esm/domain/view/viewMetrics/trackFirstInput.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackInitialViewMetrics.d.ts +15 -0
- package/esm/domain/view/viewMetrics/trackInitialViewMetrics.js +38 -0
- package/esm/domain/view/viewMetrics/trackInitialViewMetrics.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackInteractionToNextPaint.d.ts +25 -0
- package/esm/domain/view/viewMetrics/trackInteractionToNextPaint.js +149 -0
- package/esm/domain/view/viewMetrics/trackInteractionToNextPaint.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackLargestContentfulPaint.d.ts +18 -0
- package/esm/domain/view/viewMetrics/trackLargestContentfulPaint.js +57 -0
- package/esm/domain/view/viewMetrics/trackLargestContentfulPaint.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackLoadingTime.d.ts +14 -0
- package/esm/domain/view/viewMetrics/trackLoadingTime.js +47 -0
- package/esm/domain/view/viewMetrics/trackLoadingTime.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackNavigationTimings.d.ts +14 -0
- package/esm/domain/view/viewMetrics/trackNavigationTimings.js +40 -0
- package/esm/domain/view/viewMetrics/trackNavigationTimings.js.map +1 -0
- package/esm/domain/view/viewMetrics/trackScrollMetrics.d.ts +25 -0
- package/esm/domain/view/viewMetrics/trackScrollMetrics.js +72 -0
- package/esm/domain/view/viewMetrics/trackScrollMetrics.js.map +1 -0
- package/esm/domain/vital/vitalCollection.d.ts +55 -0
- package/esm/domain/vital/vitalCollection.js +107 -0
- package/esm/domain/vital/vitalCollection.js.map +1 -0
- package/esm/domain/waitPageActivityEnd.d.ts +54 -0
- package/esm/domain/waitPageActivityEnd.js +123 -0
- package/esm/domain/waitPageActivityEnd.js.map +1 -0
- package/esm/domainContext.types.d.ts +39 -0
- package/esm/domainContext.types.js +5 -0
- package/esm/domainContext.types.js.map +1 -0
- package/esm/index.d.ts +41 -0
- package/esm/index.js +21 -0
- package/esm/index.js.map +1 -0
- package/esm/rawRumEvent.types.d.ts +326 -0
- package/esm/rawRumEvent.types.js +31 -0
- package/esm/rawRumEvent.types.js.map +1 -0
- package/esm/rumEvent.types.d.ts +2026 -0
- package/esm/rumEvent.types.js +6 -0
- package/esm/rumEvent.types.js.map +1 -0
- package/esm/transport/formDataTransport.d.ts +16 -0
- package/esm/transport/formDataTransport.js +43 -0
- package/esm/transport/formDataTransport.js.map +1 -0
- package/esm/transport/startRumBatch.d.ts +5 -0
- package/esm/transport/startRumBatch.js +30 -0
- package/esm/transport/startRumBatch.js.map +1 -0
- package/esm/transport/startRumEventBridge.d.ts +2 -0
- package/esm/transport/startRumEventBridge.js +8 -0
- package/esm/transport/startRumEventBridge.js.map +1 -0
- package/package.json +29 -0
- package/src/boot/preStartRum.ts +298 -0
- package/src/boot/rumPublicApi.ts +830 -0
- package/src/boot/startRum.ts +280 -0
- package/src/browser/cookieObservable.ts +63 -0
- package/src/browser/domMutationObservable.ts +98 -0
- package/src/browser/firstInputPolyfill.ts +87 -0
- package/src/browser/htmlDomUtils.ts +45 -0
- package/src/browser/locationChangeObservable.ts +69 -0
- package/src/browser/performanceObservable.ts +324 -0
- package/src/browser/performanceUtils.ts +50 -0
- package/src/browser/scroll.ts +25 -0
- package/src/browser/viewportObservable.ts +44 -0
- package/src/browser/windowOpenObservable.ts +7 -0
- package/src/domain/action/actionCollection.ts +146 -0
- package/src/domain/action/actionNameConstants.ts +20 -0
- package/src/domain/action/clickChain.ts +83 -0
- package/src/domain/action/computeFrustration.ts +77 -0
- package/src/domain/action/getActionNameFromElement.ts +337 -0
- package/src/domain/action/interactionSelectorCache.ts +21 -0
- package/src/domain/action/listenActionEvents.ts +119 -0
- package/src/domain/action/trackClickActions.ts +388 -0
- package/src/domain/assembly.ts +141 -0
- package/src/domain/configuration/configuration.ts +548 -0
- package/src/domain/configuration/index.ts +2 -0
- package/src/domain/configuration/jsonPathParser.ts +214 -0
- package/src/domain/configuration/remoteConfiguration.ts +304 -0
- package/src/domain/configuration/remoteConfiguration.types.ts +147 -0
- package/src/domain/contexts/ciVisibilityContext.ts +50 -0
- package/src/domain/contexts/connectivityContext.ts +12 -0
- package/src/domain/contexts/defaultContext.ts +43 -0
- package/src/domain/contexts/displayContext.ts +38 -0
- package/src/domain/contexts/featureFlagContext.ts +71 -0
- package/src/domain/contexts/internalContext.ts +34 -0
- package/src/domain/contexts/pageStateHistory.ts +171 -0
- package/src/domain/contexts/sessionContext.ts +59 -0
- package/src/domain/contexts/syntheticsContext.ts +33 -0
- package/src/domain/contexts/trackingConsentContext.ts +15 -0
- package/src/domain/contexts/urlContexts.ts +97 -0
- package/src/domain/contexts/userAgentDataContext.ts +36 -0
- package/src/domain/contexts/viewHistory.ts +70 -0
- package/src/domain/discardNegativeDuration.ts +6 -0
- package/src/domain/error/errorCollection.ts +107 -0
- package/src/domain/error/trackConsoleError.ts +14 -0
- package/src/domain/error/trackReportError.ts +16 -0
- package/src/domain/event/eventCollection.ts +53 -0
- package/src/domain/getSelectorFromElement.ts +268 -0
- package/src/domain/getSessionReplayUrl.ts +47 -0
- package/src/domain/hooks.ts +31 -0
- package/src/domain/lifeCycle.ts +103 -0
- package/src/domain/limitModification.ts +66 -0
- package/src/domain/longTask/longTaskCollection.ts +133 -0
- package/src/domain/plugins.ts +59 -0
- package/src/domain/privacy.ts +355 -0
- package/src/domain/privacyConstants.ts +43 -0
- package/src/domain/requestCollection.ts +179 -0
- package/src/domain/resource/graphql.ts +135 -0
- package/src/domain/resource/matchRequestResourceEntry.ts +68 -0
- package/src/domain/resource/requestRegistry.ts +52 -0
- package/src/domain/resource/resourceCollection.ts +273 -0
- package/src/domain/resource/resourceUtils.ts +355 -0
- package/src/domain/resource/retrieveInitialDocumentResourceTiming.ts +27 -0
- package/src/domain/rumSessionManager.ts +134 -0
- package/src/domain/sampler/sampler.ts +63 -0
- package/src/domain/startCustomerDataTelemetry.ts +83 -0
- package/src/domain/tracing/getDocumentTraceId.ts +90 -0
- package/src/domain/tracing/identifier.ts +69 -0
- package/src/domain/tracing/sampler.ts +69 -0
- package/src/domain/tracing/tracer.ts +248 -0
- package/src/domain/tracing/tracer.types.ts +13 -0
- package/src/domain/trackEventCounts.ts +67 -0
- package/src/domain/view/bfCacheSupport.ts +20 -0
- package/src/domain/view/trackViewEventCounts.ts +15 -0
- package/src/domain/view/trackViews.ts +431 -0
- package/src/domain/view/viewCollection.ts +203 -0
- package/src/domain/view/viewMetrics/getClsAttributionImpactedArea.ts +34 -0
- package/src/domain/view/viewMetrics/interactionCountPolyfill.ts +55 -0
- package/src/domain/view/viewMetrics/startInitialViewMetricsTelemetry.ts +70 -0
- package/src/domain/view/viewMetrics/trackBfcacheMetrics.ts +20 -0
- package/src/domain/view/viewMetrics/trackCommonViewMetrics.ts +78 -0
- package/src/domain/view/viewMetrics/trackCumulativeLayoutShift.ts +180 -0
- package/src/domain/view/viewMetrics/trackFirstContentfulPaint.ts +47 -0
- package/src/domain/view/viewMetrics/trackFirstHidden.ts +53 -0
- package/src/domain/view/viewMetrics/trackFirstInput.ts +59 -0
- package/src/domain/view/viewMetrics/trackInitialViewMetrics.ts +66 -0
- package/src/domain/view/viewMetrics/trackInteractionToNextPaint.ts +193 -0
- package/src/domain/view/viewMetrics/trackLargestContentfulPaint.ts +87 -0
- package/src/domain/view/viewMetrics/trackLoadingTime.ts +69 -0
- package/src/domain/view/viewMetrics/trackNavigationTimings.ts +66 -0
- package/src/domain/view/viewMetrics/trackScrollMetrics.ts +119 -0
- package/src/domain/vital/vitalCollection.ts +207 -0
- package/src/domain/waitPageActivityEnd.ts +189 -0
- package/src/domainContext.types.ts +61 -0
- package/src/index.ts +76 -0
- package/src/rawRumEvent.types.ts +409 -0
- package/src/rumEvent.types.ts +2151 -0
- package/src/transport/formDataTransport.ts +85 -0
- package/src/transport/startRumBatch.ts +46 -0
- package/src/transport/startRumEventBridge.ts +12 -0
|
@@ -0,0 +1,325 @@
|
|
|
1
|
+
import type { Configuration, InitConfiguration, MatchOption } from '@kubesense/kubesense-browser-core';
|
|
2
|
+
import { DefaultPrivacyLevel, TraceContextInjection } from '@kubesense/kubesense-browser-core';
|
|
3
|
+
import type { RumEventDomainContext } from '../../domainContext.types';
|
|
4
|
+
import type { RumEvent } from '../../rumEvent.types';
|
|
5
|
+
import type { RumPlugin } from '../plugins';
|
|
6
|
+
import type { PropagatorType, TracingOption } from '../tracing/tracer.types';
|
|
7
|
+
export declare const DEFAULT_PROPAGATOR_TYPES: PropagatorType[];
|
|
8
|
+
/**
|
|
9
|
+
* Init Configuration for the RUM browser SDK.
|
|
10
|
+
*
|
|
11
|
+
* @category Main
|
|
12
|
+
* @example NPM
|
|
13
|
+
* ```ts
|
|
14
|
+
* import { kubesenseSdk } from '@kubesense/kubesense-browser-rum'
|
|
15
|
+
*
|
|
16
|
+
* kubesenseSdk.init({
|
|
17
|
+
* applicationId: '<KUBESENSE_APPLICATION_ID>',
|
|
18
|
+
* clientToken: '<KUBESENSE_CLIENT_TOKEN>',
|
|
19
|
+
* // ...
|
|
20
|
+
* })
|
|
21
|
+
* ```
|
|
22
|
+
* @example CDN
|
|
23
|
+
* ```ts
|
|
24
|
+
* KUBESENSE_SDK.init({
|
|
25
|
+
* applicationId: '<KUBESENSE_APPLICATION_ID>',
|
|
26
|
+
* clientToken: '<KUBESENSE_CLIENT_TOKEN>',
|
|
27
|
+
* ...
|
|
28
|
+
* })
|
|
29
|
+
* ```
|
|
30
|
+
*/
|
|
31
|
+
export interface RumInitConfiguration extends InitConfiguration {
|
|
32
|
+
/**
|
|
33
|
+
* The RUM application ID.
|
|
34
|
+
*
|
|
35
|
+
* @category Authentication
|
|
36
|
+
*/
|
|
37
|
+
applicationId: string;
|
|
38
|
+
/**
|
|
39
|
+
* Whether to propagate user and account IDs in the baggage header of trace requests.
|
|
40
|
+
*
|
|
41
|
+
* @category Tracing
|
|
42
|
+
* @defaultValue false
|
|
43
|
+
*/
|
|
44
|
+
propagateTraceBaggage?: boolean | undefined;
|
|
45
|
+
/**
|
|
46
|
+
* Access to every event collected by the RUM SDK before they are sent to Kubsesense.
|
|
47
|
+
* It allows:
|
|
48
|
+
* - Enrich your RUM events with additional context attributes
|
|
49
|
+
* - Modify your RUM events to modify their content, or redact sensitive sequences (see the list of editable properties)
|
|
50
|
+
* - Discard selected RUM events
|
|
51
|
+
*
|
|
52
|
+
* See [Enrich And Control Browser RUM Data With beforeSend](https://docs.kubesense.ai/real_user_monitoring/guide/enrich-and-control-rum-data) for further information.
|
|
53
|
+
*
|
|
54
|
+
* @category Data Collection
|
|
55
|
+
* @param event - The RUM event
|
|
56
|
+
* @param context - The RUM event domain context providing access to native browser data based on the event type (e.g. error, performance entry).
|
|
57
|
+
* @returns true if the event should be sent to Kubesense, false otherwise
|
|
58
|
+
*/
|
|
59
|
+
beforeSend?: ((event: RumEvent, context: RumEventDomainContext) => boolean) | undefined;
|
|
60
|
+
/**
|
|
61
|
+
* A list of request origins ignored when computing the page activity.
|
|
62
|
+
* See [How page activity is calculated](https://docs.kubesense.ai/real_user_monitoring/browser/monitoring_page_performance/#how-page-activity-is-calculated) for further information.
|
|
63
|
+
*/
|
|
64
|
+
excludedActivityUrls?: MatchOption[] | undefined;
|
|
65
|
+
/**
|
|
66
|
+
* URL pointing to the Kubesense Browser SDK Worker JavaScript file. The URL can be relative or absolute, but is required to have the same origin as the web application.
|
|
67
|
+
* See [Content Security Policy guidelines](https://docs.kubesense.ai/integrations/content_security_policy_logs/?tab=firefox#use-csp-with-real-user-monitoring-and-session-replay) for further information.
|
|
68
|
+
*
|
|
69
|
+
* @category Transport
|
|
70
|
+
*/
|
|
71
|
+
workerUrl?: string;
|
|
72
|
+
/**
|
|
73
|
+
* Compress requests sent to the Kubesense intake to reduce bandwidth usage when sending large amounts of data. The compression is done in a Worker thread.
|
|
74
|
+
* See [Content Security Policy guidelines](https://docs.kubesense.ai/integrations/content_security_policy_logs/?tab=firefox#use-csp-with-real-user-monitoring-and-session-replay) for further information.
|
|
75
|
+
*
|
|
76
|
+
* @category Transport
|
|
77
|
+
*/
|
|
78
|
+
compressIntakeRequests?: boolean | undefined;
|
|
79
|
+
/**
|
|
80
|
+
* [Internal option] Id of the remote configuration
|
|
81
|
+
*
|
|
82
|
+
* @internal
|
|
83
|
+
*/
|
|
84
|
+
remoteConfigurationId?: string | undefined;
|
|
85
|
+
/**
|
|
86
|
+
* [Internal option] set a proxy URL for the remote configuration
|
|
87
|
+
*
|
|
88
|
+
* @internal
|
|
89
|
+
*/
|
|
90
|
+
remoteConfigurationProxy?: string | undefined;
|
|
91
|
+
/**
|
|
92
|
+
* A list of request URLs used to inject tracing headers.
|
|
93
|
+
* See [Connect RUM and Traces](https://docs.kubesense.ai/real_user_monitoring/platform/connect_rum_and_traces/?tab=browserrum) for further information.
|
|
94
|
+
*
|
|
95
|
+
* @category Tracing
|
|
96
|
+
*/
|
|
97
|
+
allowedTracingUrls?: Array<MatchOption | TracingOption> | undefined;
|
|
98
|
+
/**
|
|
99
|
+
* The percentage of requests to trace: 100 for all, 0 for none.
|
|
100
|
+
* See [Connect RUM and Traces](https://docs.kubesense.ai/real_user_monitoring/platform/connect_rum_and_traces/?tab=browserrum) for further information.
|
|
101
|
+
*
|
|
102
|
+
* @category Tracing
|
|
103
|
+
*/
|
|
104
|
+
traceSampleRate?: number | undefined;
|
|
105
|
+
/**
|
|
106
|
+
* If you set a `traceSampleRate`, to ensure backend services' sampling decisions are still applied, configure the `traceContextInjection` initialization parameter to sampled.
|
|
107
|
+
*
|
|
108
|
+
* See [Connect RUM and Traces](https://docs.kubesense.ai/real_user_monitoring/platform/connect_rum_and_traces/?tab=browserrum) for further information.
|
|
109
|
+
*
|
|
110
|
+
* @category Tracing
|
|
111
|
+
* @defaultValue sampled
|
|
112
|
+
*/
|
|
113
|
+
traceContextInjection?: TraceContextInjection | undefined;
|
|
114
|
+
/**
|
|
115
|
+
* Allow to protect end user privacy and prevent sensitive organizational information from being collected.
|
|
116
|
+
*
|
|
117
|
+
* See [Replay Privacy Options](https://docs.kubesense.ai/real_user_monitoring/session_replay/browser/privacy_options) for further information.
|
|
118
|
+
*
|
|
119
|
+
* @category Privacy
|
|
120
|
+
* @defaultValue mask
|
|
121
|
+
*/
|
|
122
|
+
defaultPrivacyLevel?: DefaultPrivacyLevel | undefined;
|
|
123
|
+
/**
|
|
124
|
+
* If you are accessing Kubesense through a custom subdomain, you can set `subdomain` to include your custom domain in the `getSessionReplayLink()` returned URL .
|
|
125
|
+
*
|
|
126
|
+
* See [Connect Session Replay To Your Third-Party Tools](https://docs.kubesense.ai/real_user_monitoring/guide/connect-session-replay-to-your-third-party-tools) for further information.
|
|
127
|
+
*
|
|
128
|
+
*/
|
|
129
|
+
subdomain?: string;
|
|
130
|
+
/**
|
|
131
|
+
* The percentage of tracked sessions with [Browser RUM & Session Replay pricing](https://www.kubesense.ai/pricing/?product=real-user-monitoring--session-replay#real-user-monitoring--session-replay) features: 100 for all, 0 for none.
|
|
132
|
+
*
|
|
133
|
+
* See [Configure Your Setup For Browser RUM and Browser RUM & Session Replay Sampling](https://docs.kubesense.ai/real_user_monitoring/guide/sampling-browser-plans) for further information.
|
|
134
|
+
*
|
|
135
|
+
* @category Session Replay
|
|
136
|
+
*/
|
|
137
|
+
sessionReplaySampleRate?: number | undefined;
|
|
138
|
+
/**
|
|
139
|
+
* If the session is sampled for Session Replay, only start the recording when `startSessionReplayRecording()` is called, instead of at the beginning of the session. Default: if startSessionReplayRecording is 0, true; otherwise, false.
|
|
140
|
+
*
|
|
141
|
+
* See [Session Replay Usage](https://docs.kubesense.ai/real_user_monitoring/session_replay/browser/#usage) for further information.
|
|
142
|
+
*
|
|
143
|
+
* @category Session Replay
|
|
144
|
+
*/
|
|
145
|
+
startSessionReplayRecordingManually?: boolean | undefined;
|
|
146
|
+
/**
|
|
147
|
+
* Enables privacy control for action names.
|
|
148
|
+
*
|
|
149
|
+
* @category Privacy
|
|
150
|
+
*/
|
|
151
|
+
enablePrivacyForActionName?: boolean | undefined;
|
|
152
|
+
/**
|
|
153
|
+
* Enables automatic collection of users actions.
|
|
154
|
+
*
|
|
155
|
+
* See [Tracking User Actions](https://docs.kubesense.ai/real_user_monitoring/browser/tracking_user_actions) for further information.
|
|
156
|
+
*
|
|
157
|
+
* @category Data Collection
|
|
158
|
+
* @defaultValue true
|
|
159
|
+
*/
|
|
160
|
+
trackUserInteractions?: boolean | undefined;
|
|
161
|
+
/**
|
|
162
|
+
* Specify your own attribute to use to name actions.
|
|
163
|
+
*
|
|
164
|
+
* See [Declare a name for click actions](https://docs.kubesense.ai/real_user_monitoring/browser/tracking_user_actions/#declare-a-name-for-click-actions) for further information.
|
|
165
|
+
*
|
|
166
|
+
* @category Data Collection
|
|
167
|
+
*/
|
|
168
|
+
actionNameAttribute?: string | undefined;
|
|
169
|
+
/**
|
|
170
|
+
* Allows you to control RUM views creation. See [Override default RUM view names](https://docs.kubesense.ai/real_user_monitoring/browser/advanced_configuration/?tab=npm#override-default-rum-view-names) for further information.
|
|
171
|
+
*
|
|
172
|
+
* @category Data Collection
|
|
173
|
+
*/
|
|
174
|
+
trackViewsManually?: boolean | undefined;
|
|
175
|
+
/**
|
|
176
|
+
* Enable the creation of dedicated views for pages restored from the Back-Forward cache.
|
|
177
|
+
*
|
|
178
|
+
* @category Data Collection
|
|
179
|
+
* @defaultValue false
|
|
180
|
+
*/
|
|
181
|
+
trackBfcacheViews?: boolean | undefined;
|
|
182
|
+
/**
|
|
183
|
+
* Enables collection of resource events.
|
|
184
|
+
*
|
|
185
|
+
* @category Data Collection
|
|
186
|
+
* @defaultValue true
|
|
187
|
+
*/
|
|
188
|
+
trackResources?: boolean | undefined;
|
|
189
|
+
/**
|
|
190
|
+
* Enables collection of long task events.
|
|
191
|
+
*
|
|
192
|
+
* @category Data Collection
|
|
193
|
+
* @defaultValue true
|
|
194
|
+
*/
|
|
195
|
+
trackLongTasks?: boolean | undefined;
|
|
196
|
+
/**
|
|
197
|
+
* Enables early request collection before resource timing entries are available.
|
|
198
|
+
*
|
|
199
|
+
* @category Data Collection
|
|
200
|
+
* @defaultValue false
|
|
201
|
+
*/
|
|
202
|
+
trackEarlyRequests?: boolean | undefined;
|
|
203
|
+
/**
|
|
204
|
+
* List of plugins to enable. The plugins API is unstable and experimental, and may change without
|
|
205
|
+
* notice. Please use only plugins provided by Kubesense matching the version of the SDK you are
|
|
206
|
+
* using.
|
|
207
|
+
*/
|
|
208
|
+
plugins?: RumPlugin[] | undefined;
|
|
209
|
+
/**
|
|
210
|
+
* Enables collection of features flags in additional events (e.g. long task, resource, action, vital).
|
|
211
|
+
*
|
|
212
|
+
* @category Data Collection
|
|
213
|
+
*/
|
|
214
|
+
trackFeatureFlagsForEvents?: FeatureFlagsForEvents[];
|
|
215
|
+
/**
|
|
216
|
+
* The percentage of users profiled. A value between 0 and 100.
|
|
217
|
+
*
|
|
218
|
+
* @category Profiling
|
|
219
|
+
* @defaultValue 0
|
|
220
|
+
*/
|
|
221
|
+
profilingSampleRate?: number | undefined;
|
|
222
|
+
/**
|
|
223
|
+
* A list of GraphQL endpoint URLs to track and enrich with GraphQL-specific metadata.
|
|
224
|
+
*
|
|
225
|
+
* @category Data Collection
|
|
226
|
+
*/
|
|
227
|
+
allowedGraphQlUrls?: Array<MatchOption | GraphQlUrlOption> | undefined;
|
|
228
|
+
/**
|
|
229
|
+
* A list of domains to treat as first-party in resource provider classification.
|
|
230
|
+
* Accepts strings (exact hostname match), RegExp, or functions.
|
|
231
|
+
* The current page hostname is always treated as first-party.
|
|
232
|
+
*
|
|
233
|
+
* @category Data Collection
|
|
234
|
+
* @example ['api.myapp.com', /\.myapp\.com$/, (host) => host.endsWith('.internal')]
|
|
235
|
+
*/
|
|
236
|
+
firstPartyDomains?: MatchOption[] | undefined;
|
|
237
|
+
}
|
|
238
|
+
export type HybridInitConfiguration = Omit<RumInitConfiguration, 'applicationId' | 'clientToken'>;
|
|
239
|
+
export type FeatureFlagsForEvents = 'vital' | 'action' | 'long_task' | 'resource';
|
|
240
|
+
export interface GraphQlUrlOption {
|
|
241
|
+
match: MatchOption;
|
|
242
|
+
trackPayload?: boolean;
|
|
243
|
+
trackResponseErrors?: boolean;
|
|
244
|
+
}
|
|
245
|
+
export interface RumConfiguration extends Configuration {
|
|
246
|
+
actionNameAttribute: string | undefined;
|
|
247
|
+
traceSampleRate: number;
|
|
248
|
+
rulePsr: number | undefined;
|
|
249
|
+
allowedTracingUrls: TracingOption[];
|
|
250
|
+
excludedActivityUrls: MatchOption[];
|
|
251
|
+
workerUrl: string | undefined;
|
|
252
|
+
compressIntakeRequests: boolean;
|
|
253
|
+
applicationId: string;
|
|
254
|
+
defaultPrivacyLevel: DefaultPrivacyLevel;
|
|
255
|
+
enablePrivacyForActionName: boolean;
|
|
256
|
+
sessionReplaySampleRate: number;
|
|
257
|
+
startSessionReplayRecordingManually: boolean;
|
|
258
|
+
trackUserInteractions: boolean;
|
|
259
|
+
trackViewsManually: boolean;
|
|
260
|
+
trackResources: boolean;
|
|
261
|
+
trackLongTasks: boolean;
|
|
262
|
+
trackBfcacheViews: boolean;
|
|
263
|
+
trackEarlyRequests: boolean;
|
|
264
|
+
subdomain?: string;
|
|
265
|
+
traceContextInjection: TraceContextInjection;
|
|
266
|
+
plugins: RumPlugin[];
|
|
267
|
+
trackFeatureFlagsForEvents: FeatureFlagsForEvents[];
|
|
268
|
+
profilingSampleRate: number;
|
|
269
|
+
propagateTraceBaggage: boolean;
|
|
270
|
+
allowedGraphQlUrls: GraphQlUrlOption[];
|
|
271
|
+
firstPartyDomains: MatchOption[];
|
|
272
|
+
}
|
|
273
|
+
export declare function validateAndBuildRumConfiguration(initConfiguration: RumInitConfiguration, errorStack?: string): RumConfiguration | undefined;
|
|
274
|
+
export declare function serializeRumConfiguration(configuration: RumInitConfiguration): {
|
|
275
|
+
session_sample_rate: number | undefined;
|
|
276
|
+
telemetry_sample_rate: number | undefined;
|
|
277
|
+
telemetry_configuration_sample_rate: number | undefined;
|
|
278
|
+
telemetry_usage_sample_rate: number | undefined;
|
|
279
|
+
use_before_send: boolean;
|
|
280
|
+
use_partitioned_cross_site_session_cookie: boolean | undefined;
|
|
281
|
+
use_secure_session_cookie: boolean | undefined;
|
|
282
|
+
use_proxy: boolean;
|
|
283
|
+
silent_multiple_init: boolean | undefined;
|
|
284
|
+
track_session_across_subdomains: boolean | undefined;
|
|
285
|
+
track_anonymous_user: boolean | undefined;
|
|
286
|
+
session_persistence: import("@kubesense/kubesense-browser-core").SessionPersistence | undefined;
|
|
287
|
+
allow_fallback_to_local_storage: boolean;
|
|
288
|
+
store_contexts_across_pages: boolean;
|
|
289
|
+
allow_untrusted_events: boolean;
|
|
290
|
+
tracking_consent: import("@kubesense/kubesense-browser-core").TrackingConsent | undefined;
|
|
291
|
+
use_allowed_tracking_origins: boolean;
|
|
292
|
+
beta_encode_cookie_options: boolean | undefined;
|
|
293
|
+
source: "browser" | "flutter" | "unity" | undefined;
|
|
294
|
+
sdk_version: string | undefined;
|
|
295
|
+
variant: string | undefined;
|
|
296
|
+
session_replay_sample_rate: number | undefined;
|
|
297
|
+
start_session_replay_recording_manually: boolean | undefined;
|
|
298
|
+
trace_sample_rate: number | undefined;
|
|
299
|
+
trace_context_injection: TraceContextInjection | undefined;
|
|
300
|
+
propagate_trace_baggage: boolean | undefined;
|
|
301
|
+
action_name_attribute: string | undefined;
|
|
302
|
+
use_allowed_tracing_urls: boolean;
|
|
303
|
+
use_allowed_graph_ql_urls: boolean;
|
|
304
|
+
use_track_graph_ql_payload: boolean;
|
|
305
|
+
use_track_graph_ql_response_errors: boolean;
|
|
306
|
+
selected_tracing_propagators: PropagatorType[];
|
|
307
|
+
default_privacy_level: DefaultPrivacyLevel | undefined;
|
|
308
|
+
enable_privacy_for_action_name: boolean | undefined;
|
|
309
|
+
use_excluded_activity_urls: boolean;
|
|
310
|
+
use_worker_url: boolean;
|
|
311
|
+
compress_intake_requests: boolean | undefined;
|
|
312
|
+
track_views_manually: boolean | undefined;
|
|
313
|
+
track_user_interactions: boolean | undefined;
|
|
314
|
+
track_resources: boolean | undefined;
|
|
315
|
+
track_long_task: boolean | undefined;
|
|
316
|
+
track_bfcache_views: boolean | undefined;
|
|
317
|
+
track_early_requests: boolean | undefined;
|
|
318
|
+
plugins: {
|
|
319
|
+
name: string;
|
|
320
|
+
}[] | undefined;
|
|
321
|
+
track_feature_flags_for_events: FeatureFlagsForEvents[] | undefined;
|
|
322
|
+
remote_configuration_id: string | undefined;
|
|
323
|
+
profiling_sample_rate: number | undefined;
|
|
324
|
+
use_remote_configuration_proxy: boolean;
|
|
325
|
+
};
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DEFAULT_PROPAGATOR_TYPES = void 0;
|
|
4
|
+
exports.validateAndBuildRumConfiguration = validateAndBuildRumConfiguration;
|
|
5
|
+
exports.serializeRumConfiguration = serializeRumConfiguration;
|
|
6
|
+
const kubesense_browser_core_1 = require("@kubesense/kubesense-browser-core");
|
|
7
|
+
const tracer_1 = require("../tracing/tracer");
|
|
8
|
+
exports.DEFAULT_PROPAGATOR_TYPES = ['tracecontext', 'kubesense'];
|
|
9
|
+
function validateAndBuildRumConfiguration(initConfiguration, errorStack) {
|
|
10
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
11
|
+
if (initConfiguration.trackFeatureFlagsForEvents !== undefined &&
|
|
12
|
+
!Array.isArray(initConfiguration.trackFeatureFlagsForEvents)) {
|
|
13
|
+
kubesense_browser_core_1.display.warn('trackFeatureFlagsForEvents should be an array');
|
|
14
|
+
}
|
|
15
|
+
if (!initConfiguration.applicationId) {
|
|
16
|
+
kubesense_browser_core_1.display.error('Application ID is not configured, no RUM data will be collected.');
|
|
17
|
+
return;
|
|
18
|
+
}
|
|
19
|
+
if (!(0, kubesense_browser_core_1.isSampleRate)(initConfiguration.sessionReplaySampleRate, 'Session Replay') ||
|
|
20
|
+
!(0, kubesense_browser_core_1.isSampleRate)(initConfiguration.traceSampleRate, 'Trace')) {
|
|
21
|
+
return;
|
|
22
|
+
}
|
|
23
|
+
if (initConfiguration.excludedActivityUrls !== undefined && !Array.isArray(initConfiguration.excludedActivityUrls)) {
|
|
24
|
+
kubesense_browser_core_1.display.error('Excluded Activity Urls should be an array');
|
|
25
|
+
return;
|
|
26
|
+
}
|
|
27
|
+
const allowedTracingUrls = validateAndBuildTracingOptions(initConfiguration);
|
|
28
|
+
if (!allowedTracingUrls) {
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
const baseConfiguration = (0, kubesense_browser_core_1.validateAndBuildConfiguration)(initConfiguration, errorStack);
|
|
32
|
+
const allowedGraphQlUrls = validateAndBuildGraphQlOptions(initConfiguration);
|
|
33
|
+
if (!baseConfiguration) {
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
const sessionReplaySampleRate = (_a = initConfiguration.sessionReplaySampleRate) !== null && _a !== void 0 ? _a : 0;
|
|
37
|
+
return {
|
|
38
|
+
applicationId: initConfiguration.applicationId,
|
|
39
|
+
actionNameAttribute: initConfiguration.actionNameAttribute,
|
|
40
|
+
sessionReplaySampleRate,
|
|
41
|
+
startSessionReplayRecordingManually: initConfiguration.startSessionReplayRecordingManually !== undefined
|
|
42
|
+
? !!initConfiguration.startSessionReplayRecordingManually
|
|
43
|
+
: sessionReplaySampleRate === 0,
|
|
44
|
+
traceSampleRate: (_b = initConfiguration.traceSampleRate) !== null && _b !== void 0 ? _b : 100,
|
|
45
|
+
rulePsr: (0, kubesense_browser_core_1.isNumber)(initConfiguration.traceSampleRate) ? initConfiguration.traceSampleRate / 100 : undefined,
|
|
46
|
+
allowedTracingUrls,
|
|
47
|
+
excludedActivityUrls: (_c = initConfiguration.excludedActivityUrls) !== null && _c !== void 0 ? _c : [],
|
|
48
|
+
workerUrl: initConfiguration.workerUrl,
|
|
49
|
+
compressIntakeRequests: !!initConfiguration.compressIntakeRequests,
|
|
50
|
+
trackUserInteractions: !!((_d = initConfiguration.trackUserInteractions) !== null && _d !== void 0 ? _d : true),
|
|
51
|
+
trackViewsManually: !!initConfiguration.trackViewsManually,
|
|
52
|
+
trackResources: !!((_e = initConfiguration.trackResources) !== null && _e !== void 0 ? _e : true),
|
|
53
|
+
trackLongTasks: !!((_f = initConfiguration.trackLongTasks) !== null && _f !== void 0 ? _f : true),
|
|
54
|
+
trackBfcacheViews: !!initConfiguration.trackBfcacheViews,
|
|
55
|
+
trackEarlyRequests: !!initConfiguration.trackEarlyRequests,
|
|
56
|
+
subdomain: initConfiguration.subdomain,
|
|
57
|
+
defaultPrivacyLevel: (0, kubesense_browser_core_1.objectHasValue)(kubesense_browser_core_1.DefaultPrivacyLevel, initConfiguration.defaultPrivacyLevel)
|
|
58
|
+
? initConfiguration.defaultPrivacyLevel
|
|
59
|
+
: kubesense_browser_core_1.DefaultPrivacyLevel.MASK,
|
|
60
|
+
enablePrivacyForActionName: !!initConfiguration.enablePrivacyForActionName,
|
|
61
|
+
traceContextInjection: (0, kubesense_browser_core_1.objectHasValue)(kubesense_browser_core_1.TraceContextInjection, initConfiguration.traceContextInjection)
|
|
62
|
+
? initConfiguration.traceContextInjection
|
|
63
|
+
: kubesense_browser_core_1.TraceContextInjection.SAMPLED,
|
|
64
|
+
plugins: initConfiguration.plugins || [],
|
|
65
|
+
trackFeatureFlagsForEvents: initConfiguration.trackFeatureFlagsForEvents || [],
|
|
66
|
+
profilingSampleRate: (_g = initConfiguration.profilingSampleRate) !== null && _g !== void 0 ? _g : 0,
|
|
67
|
+
propagateTraceBaggage: !!initConfiguration.propagateTraceBaggage,
|
|
68
|
+
allowedGraphQlUrls,
|
|
69
|
+
firstPartyDomains: (_h = initConfiguration.firstPartyDomains) !== null && _h !== void 0 ? _h : [],
|
|
70
|
+
...baseConfiguration,
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Validates allowedTracingUrls and converts match options to tracing options
|
|
75
|
+
*/
|
|
76
|
+
function validateAndBuildTracingOptions(initConfiguration) {
|
|
77
|
+
if (initConfiguration.allowedTracingUrls === undefined) {
|
|
78
|
+
return [];
|
|
79
|
+
}
|
|
80
|
+
if (!Array.isArray(initConfiguration.allowedTracingUrls)) {
|
|
81
|
+
kubesense_browser_core_1.display.error('Allowed Tracing URLs should be an array');
|
|
82
|
+
return;
|
|
83
|
+
}
|
|
84
|
+
if (initConfiguration.allowedTracingUrls.length !== 0 && initConfiguration.service === undefined) {
|
|
85
|
+
kubesense_browser_core_1.display.error('Service needs to be configured when tracing is enabled');
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
// Convert from (MatchOption | TracingOption) to TracingOption, remove unknown properties
|
|
89
|
+
const tracingOptions = [];
|
|
90
|
+
initConfiguration.allowedTracingUrls.forEach((option) => {
|
|
91
|
+
if ((0, kubesense_browser_core_1.isMatchOption)(option)) {
|
|
92
|
+
tracingOptions.push({ match: option, propagatorTypes: exports.DEFAULT_PROPAGATOR_TYPES });
|
|
93
|
+
}
|
|
94
|
+
else if ((0, tracer_1.isTracingOption)(option)) {
|
|
95
|
+
tracingOptions.push(option);
|
|
96
|
+
}
|
|
97
|
+
else {
|
|
98
|
+
kubesense_browser_core_1.display.warn('Allowed Tracing Urls parameters should be a string, RegExp, function, or an object. Ignoring parameter', option);
|
|
99
|
+
}
|
|
100
|
+
});
|
|
101
|
+
return tracingOptions;
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Combines the selected tracing propagators from the different options in allowedTracingUrls
|
|
105
|
+
*/
|
|
106
|
+
function getSelectedTracingPropagators(configuration) {
|
|
107
|
+
const usedTracingPropagators = new Set();
|
|
108
|
+
if ((0, kubesense_browser_core_1.isNonEmptyArray)(configuration.allowedTracingUrls)) {
|
|
109
|
+
configuration.allowedTracingUrls.forEach((option) => {
|
|
110
|
+
if ((0, kubesense_browser_core_1.isMatchOption)(option)) {
|
|
111
|
+
exports.DEFAULT_PROPAGATOR_TYPES.forEach((propagatorType) => usedTracingPropagators.add(propagatorType));
|
|
112
|
+
}
|
|
113
|
+
else if ((0, kubesense_browser_core_1.getType)(option) === 'object' && Array.isArray(option.propagatorTypes)) {
|
|
114
|
+
// Ensure we have an array, as we cannot rely on types yet (configuration is provided by users)
|
|
115
|
+
option.propagatorTypes.forEach((propagatorType) => usedTracingPropagators.add(propagatorType));
|
|
116
|
+
}
|
|
117
|
+
});
|
|
118
|
+
}
|
|
119
|
+
return Array.from(usedTracingPropagators);
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* Build GraphQL options from configuration
|
|
123
|
+
*/
|
|
124
|
+
function validateAndBuildGraphQlOptions(initConfiguration) {
|
|
125
|
+
if (!initConfiguration.allowedGraphQlUrls) {
|
|
126
|
+
return [];
|
|
127
|
+
}
|
|
128
|
+
if (!Array.isArray(initConfiguration.allowedGraphQlUrls)) {
|
|
129
|
+
kubesense_browser_core_1.display.warn('allowedGraphQlUrls should be an array');
|
|
130
|
+
return [];
|
|
131
|
+
}
|
|
132
|
+
const graphQlOptions = [];
|
|
133
|
+
initConfiguration.allowedGraphQlUrls.forEach((option) => {
|
|
134
|
+
if ((0, kubesense_browser_core_1.isMatchOption)(option)) {
|
|
135
|
+
graphQlOptions.push({ match: option, trackPayload: false, trackResponseErrors: false });
|
|
136
|
+
}
|
|
137
|
+
else if (option && typeof option === 'object' && 'match' in option && (0, kubesense_browser_core_1.isMatchOption)(option.match)) {
|
|
138
|
+
graphQlOptions.push({
|
|
139
|
+
match: option.match,
|
|
140
|
+
trackPayload: !!option.trackPayload,
|
|
141
|
+
trackResponseErrors: !!option.trackResponseErrors,
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
});
|
|
145
|
+
return graphQlOptions;
|
|
146
|
+
}
|
|
147
|
+
function hasGraphQlPayloadTracking(allowedGraphQlUrls) {
|
|
148
|
+
return ((0, kubesense_browser_core_1.isNonEmptyArray)(allowedGraphQlUrls) &&
|
|
149
|
+
allowedGraphQlUrls.some((option) => {
|
|
150
|
+
if (typeof option === 'object' && 'trackPayload' in option) {
|
|
151
|
+
return !!option.trackPayload;
|
|
152
|
+
}
|
|
153
|
+
return false;
|
|
154
|
+
}));
|
|
155
|
+
}
|
|
156
|
+
function hasGraphQlResponseErrorsTracking(allowedGraphQlUrls) {
|
|
157
|
+
return ((0, kubesense_browser_core_1.isNonEmptyArray)(allowedGraphQlUrls) &&
|
|
158
|
+
allowedGraphQlUrls.some((option) => {
|
|
159
|
+
if (typeof option === 'object' && 'trackResponseErrors' in option) {
|
|
160
|
+
return !!option.trackResponseErrors;
|
|
161
|
+
}
|
|
162
|
+
return false;
|
|
163
|
+
}));
|
|
164
|
+
}
|
|
165
|
+
function serializeRumConfiguration(configuration) {
|
|
166
|
+
var _a;
|
|
167
|
+
const baseSerializedConfiguration = (0, kubesense_browser_core_1.serializeConfiguration)(configuration);
|
|
168
|
+
return {
|
|
169
|
+
session_replay_sample_rate: configuration.sessionReplaySampleRate,
|
|
170
|
+
start_session_replay_recording_manually: configuration.startSessionReplayRecordingManually,
|
|
171
|
+
trace_sample_rate: configuration.traceSampleRate,
|
|
172
|
+
trace_context_injection: configuration.traceContextInjection,
|
|
173
|
+
propagate_trace_baggage: configuration.propagateTraceBaggage,
|
|
174
|
+
action_name_attribute: configuration.actionNameAttribute,
|
|
175
|
+
use_allowed_tracing_urls: (0, kubesense_browser_core_1.isNonEmptyArray)(configuration.allowedTracingUrls),
|
|
176
|
+
use_allowed_graph_ql_urls: (0, kubesense_browser_core_1.isNonEmptyArray)(configuration.allowedGraphQlUrls),
|
|
177
|
+
use_track_graph_ql_payload: hasGraphQlPayloadTracking(configuration.allowedGraphQlUrls),
|
|
178
|
+
use_track_graph_ql_response_errors: hasGraphQlResponseErrorsTracking(configuration.allowedGraphQlUrls),
|
|
179
|
+
selected_tracing_propagators: getSelectedTracingPropagators(configuration),
|
|
180
|
+
default_privacy_level: configuration.defaultPrivacyLevel,
|
|
181
|
+
enable_privacy_for_action_name: configuration.enablePrivacyForActionName,
|
|
182
|
+
use_excluded_activity_urls: (0, kubesense_browser_core_1.isNonEmptyArray)(configuration.excludedActivityUrls),
|
|
183
|
+
use_worker_url: !!configuration.workerUrl,
|
|
184
|
+
compress_intake_requests: configuration.compressIntakeRequests,
|
|
185
|
+
track_views_manually: configuration.trackViewsManually,
|
|
186
|
+
track_user_interactions: configuration.trackUserInteractions,
|
|
187
|
+
track_resources: configuration.trackResources,
|
|
188
|
+
track_long_task: configuration.trackLongTasks,
|
|
189
|
+
track_bfcache_views: configuration.trackBfcacheViews,
|
|
190
|
+
track_early_requests: configuration.trackEarlyRequests,
|
|
191
|
+
plugins: (_a = configuration.plugins) === null || _a === void 0 ? void 0 : _a.map((plugin) => {
|
|
192
|
+
var _a;
|
|
193
|
+
return ({
|
|
194
|
+
name: plugin.name,
|
|
195
|
+
...(_a = plugin.getConfigurationTelemetry) === null || _a === void 0 ? void 0 : _a.call(plugin),
|
|
196
|
+
});
|
|
197
|
+
}),
|
|
198
|
+
track_feature_flags_for_events: configuration.trackFeatureFlagsForEvents,
|
|
199
|
+
remote_configuration_id: configuration.remoteConfigurationId,
|
|
200
|
+
profiling_sample_rate: configuration.profilingSampleRate,
|
|
201
|
+
use_remote_configuration_proxy: !!configuration.remoteConfigurationProxy,
|
|
202
|
+
...baseSerializedConfiguration,
|
|
203
|
+
};
|
|
204
|
+
}
|
|
205
|
+
//# sourceMappingURL=configuration.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"configuration.js","sourceRoot":"","sources":["../../../src/domain/configuration/configuration.ts"],"names":[],"mappings":";;;AAmUA,4EA+EC;AA6GD,8DAoCC;AAliBD,8EAY0C;AAI1C,8CAAmD;AAGtC,QAAA,wBAAwB,GAAqB,CAAC,cAAc,EAAE,WAAW,CAAC,CAAA;AA+SvF,SAAgB,gCAAgC,CAC9C,iBAAuC,EACvC,UAAmB;;IAEnB,IACE,iBAAiB,CAAC,0BAA0B,KAAK,SAAS;QAC1D,CAAC,KAAK,CAAC,OAAO,CAAC,iBAAiB,CAAC,0BAA0B,CAAC,EAC5D,CAAC;QACD,gCAAO,CAAC,IAAI,CAAC,+CAA+C,CAAC,CAAA;IAC/D,CAAC;IAED,IAAI,CAAC,iBAAiB,CAAC,aAAa,EAAE,CAAC;QACrC,gCAAO,CAAC,KAAK,CAAC,kEAAkE,CAAC,CAAA;QACjF,OAAM;IACR,CAAC;IAED,IACE,CAAC,IAAA,qCAAY,EAAC,iBAAiB,CAAC,uBAAuB,EAAE,gBAAgB,CAAC;QAC1E,CAAC,IAAA,qCAAY,EAAC,iBAAiB,CAAC,eAAe,EAAE,OAAO,CAAC,EACzD,CAAC;QACD,OAAM;IACR,CAAC;IAED,IAAI,iBAAiB,CAAC,oBAAoB,KAAK,SAAS,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,iBAAiB,CAAC,oBAAoB,CAAC,EAAE,CAAC;QACnH,gCAAO,CAAC,KAAK,CAAC,2CAA2C,CAAC,CAAA;QAC1D,OAAM;IACR,CAAC;IAED,MAAM,kBAAkB,GAAG,8BAA8B,CAAC,iBAAiB,CAAC,CAAA;IAC5E,IAAI,CAAC,kBAAkB,EAAE,CAAC;QACxB,OAAM;IACR,CAAC;IAED,MAAM,iBAAiB,GAAG,IAAA,sDAA6B,EAAC,iBAAiB,EAAE,UAAU,CAAC,CAAA;IAEtF,M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B,CAAC,aAAa,CAAC;QAC1E,qBAAqB,EAAE,aAAa,CAAC,mBAAmB;QACxD,8BAA8B,EAAE,aAAa,CAAC,0BAA0B;QACxE,0BAA0B,EAAE,IAAA,wCAAe,EAAC,aAAa,CAAC,oBAAoB,CAAC;QAC/E,cAAc,EAAE,CAAC,CAAC,aAAa,CAAC,SAAS;QACzC,wBAAwB,EAAE,aAAa,CAAC,sBAAsB;QAC9D,oBAAoB,EAAE,aAAa,CAAC,kBAAkB;QACtD,uBAAuB,EAAE,aAAa,CAAC,qBAAqB;QAC5D,eAAe,EAAE,aAAa,CAAC,cAAc;QAC7C,eAAe,EAAE,aAAa,CAAC,cAAc;QAC7C,mBAAmB,EAAE,aAAa,CAAC,iBAAiB;QACpD,oBAAoB,EAAE,aAAa,CAAC,kBAAkB;QACtD,OAAO,EAAE,MAAA,aAAa,CAAC,OAAO,0CAAE,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE;;YAAC,OAAA,CAAC;gBAC/C,IAAI,EAAE,MAAM,CAAC,IAAI;gBACjB,GAAG,MAAA,MAAM,CAAC,yBAAyB,sDAAI;aACxC,CAAC,CAAA;SAAA,CAAC;QACH,8BAA8B,EAAE,aAAa,CAAC,0BAA0B;QACxE,uBAAuB,EAAE,aAAa,CAAC,qBAAqB;QAC5D,qBAAqB,EAAE,aAAa,CAAC,mBAAmB;QACxD,8BAA8B,EAAE,CAAC,CAAC,aAAa,CAAC,wBAAwB;QACxE,GAAG,2BAA2B;KACK,CAAA;AACvC,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./configuration"), exports);
|
|
18
|
+
__exportStar(require("./remoteConfiguration"), exports);
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/domain/configuration/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kDAA+B;AAC/B,wDAAqC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Terminology inspired from https://www.rfc-editor.org/rfc/rfc9535.html
|
|
3
|
+
*
|
|
4
|
+
* jsonpath-query = segment*
|
|
5
|
+
* segment = .name-shorthand / bracketed-selection
|
|
6
|
+
* bracketed-selection = ['name-selector'] / ["name-selector"] / [index-selector]
|
|
7
|
+
*
|
|
8
|
+
* Useful references:
|
|
9
|
+
* - https://goessner.net/articles/JsonPath/
|
|
10
|
+
* - https://jsonpath.com/
|
|
11
|
+
* - https://github.com/jsonpath-standard
|
|
12
|
+
*/
|
|
13
|
+
/**
|
|
14
|
+
* Extract selectors from a simple JSON path expression, return [] for an invalid path
|
|
15
|
+
*
|
|
16
|
+
* Supports:
|
|
17
|
+
* - Dot notation: `foo.bar.baz`
|
|
18
|
+
* - Bracket notation: `['foo']["bar"]`
|
|
19
|
+
* - Array indices: `items[0]`, `data['users'][1]`
|
|
20
|
+
*
|
|
21
|
+
* Examples:
|
|
22
|
+
* parseJsonPath("['foo'].bar[12]")
|
|
23
|
+
* => ['foo', 'bar', '12']
|
|
24
|
+
*
|
|
25
|
+
* parseJsonPath("['foo")
|
|
26
|
+
* => []
|
|
27
|
+
*/
|
|
28
|
+
export declare function parseJsonPath(path: string): string[];
|