🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
DemoInstallSign in
Socket

@sentry-internal/browser-utils

Package Overview
Dependencies
Maintainers
9
Versions
130
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sentry-internal/browser-utils - npm Package Compare versions

Comparing version

to
9.25.0

10

build/cjs/metrics/browserMetrics.js

@@ -268,3 +268,3 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });

case 'measure': {
_addMeasureSpans(span, entry, startTime, duration, timeOrigin);
_addMeasureSpans(span, entry, startTime, duration, timeOrigin, options.ignorePerformanceApiSpans);

@@ -363,3 +363,11 @@ // capture web vitals

timeOrigin,
ignorePerformanceApiSpans,
) {
if (
['mark', 'measure'].includes(entry.entryType) &&
core.stringMatchesSomePattern(entry.name, ignorePerformanceApiSpans)
) {
return;
}
const navEntry = getNavigationEntry.getNavigationEntry(false);

@@ -366,0 +374,0 @@ const requestTime = utils.msToSec(navEntry ? navEntry.requestStart : 0);

@@ -1,2 +0,2 @@

import { browserPerformanceTimeOrigin, spanToJSON, setMeasurement, getActiveSpan, parseUrl, SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN, htmlTreeAsString, getComponentName } from '@sentry/core';
import { browserPerformanceTimeOrigin, spanToJSON, setMeasurement, getActiveSpan, parseUrl, stringMatchesSomePattern, SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN, htmlTreeAsString, getComponentName } from '@sentry/core';
import { WINDOW } from '../types.js';

@@ -266,3 +266,3 @@ import { trackClsAsStandaloneSpan } from './cls.js';

case 'measure': {
_addMeasureSpans(span, entry, startTime, duration, timeOrigin);
_addMeasureSpans(span, entry, startTime, duration, timeOrigin, options.ignorePerformanceApiSpans);

@@ -361,3 +361,11 @@ // capture web vitals

timeOrigin,
ignorePerformanceApiSpans,
) {
if (
['mark', 'measure'].includes(entry.entryType) &&
stringMatchesSomePattern(entry.name, ignorePerformanceApiSpans)
) {
return;
}
const navEntry = getNavigationEntry(false);

@@ -364,0 +372,0 @@ const requestTime = msToSec(navEntry ? navEntry.requestStart : 0);

2

build/esm/package.json

@@ -1,1 +0,1 @@

{"type":"module","version":"9.24.0","sideEffects":false}
{"type":"module","version":"9.25.0","sideEffects":false}

@@ -37,2 +37,10 @@ import { Span } from '@sentry/core';

ignoreResourceSpans: Array<'resouce.script' | 'resource.css' | 'resource.img' | 'resource.other' | string>;
/**
* Performance spans created from browser Performance APIs,
* `performance.mark(...)` nand `performance.measure(...)`
* with `name`s matching strings in the array will not be emitted.
*
* Default: []
*/
ignorePerformanceApiSpans: Array<string | RegExp>;
}

@@ -45,3 +53,3 @@ /** Add performance related spans to a transaction */

*/
export declare function _addMeasureSpans(span: Span, entry: PerformanceEntry, startTime: number, duration: number, timeOrigin: number): void;
export declare function _addMeasureSpans(span: Span, entry: PerformanceEntry, startTime: number, duration: number, timeOrigin: number, ignorePerformanceApiSpans: AddPerformanceEntriesOptions['ignorePerformanceApiSpans']): void;
/**

@@ -48,0 +56,0 @@ * Instrument navigation entries

@@ -37,2 +37,10 @@ import type { Span } from '@sentry/core';

ignoreResourceSpans: Array<'resouce.script' | 'resource.css' | 'resource.img' | 'resource.other' | string>;
/**
* Performance spans created from browser Performance APIs,
* `performance.mark(...)` nand `performance.measure(...)`
* with `name`s matching strings in the array will not be emitted.
*
* Default: []
*/
ignorePerformanceApiSpans: Array<string | RegExp>;
}

@@ -45,3 +53,3 @@ /** Add performance related spans to a transaction */

*/
export declare function _addMeasureSpans(span: Span, entry: PerformanceEntry, startTime: number, duration: number, timeOrigin: number): void;
export declare function _addMeasureSpans(span: Span, entry: PerformanceEntry, startTime: number, duration: number, timeOrigin: number, ignorePerformanceApiSpans: AddPerformanceEntriesOptions['ignorePerformanceApiSpans']): void;
/**

@@ -48,0 +56,0 @@ * Instrument navigation entries

{
"name": "@sentry-internal/browser-utils",
"version": "9.24.0",
"version": "9.25.0",
"description": "Browser Utilities for all Sentry JavaScript SDKs",

@@ -42,3 +42,3 @@ "repository": "git://github.com/getsentry/sentry-javascript.git",

"dependencies": {
"@sentry/core": "9.24.0"
"@sentry/core": "9.25.0"
},

@@ -45,0 +45,0 @@ "scripts": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet