@grafana/faro-core 1.12.3 → 1.13.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/dist/bundle/faro-core.iife.js +1 -1
- package/dist/bundle/types/api/exceptions/const.d.ts +1 -0
- package/dist/bundle/types/api/exceptions/index.d.ts +1 -1
- package/dist/bundle/types/api/index.d.ts +1 -1
- package/dist/bundle/types/api/meta/types.d.ts +13 -3
- package/dist/bundle/types/config/types.d.ts +21 -1
- package/dist/bundle/types/index.d.ts +3 -3
- package/dist/bundle/types/metas/index.d.ts +1 -1
- package/dist/bundle/types/metas/types.d.ts +7 -0
- package/dist/bundle/types/semantic.d.ts +1 -0
- package/dist/bundle/types/testUtils/mockTransport.d.ts +1 -1
- package/dist/bundle/types/utils/index.d.ts +2 -1
- package/dist/bundle/types/utils/is.d.ts +1 -0
- package/dist/bundle/types/utils/json.d.ts +2 -0
- package/dist/bundle/types/version.d.ts +1 -1
- package/dist/cjs/api/exceptions/const.js +13 -1
- package/dist/cjs/api/exceptions/const.js.map +1 -1
- package/dist/cjs/api/exceptions/index.js +2 -1
- package/dist/cjs/api/exceptions/index.js.map +1 -1
- package/dist/cjs/api/index.js +2 -1
- package/dist/cjs/api/index.js.map +1 -1
- package/dist/cjs/api/meta/initialize.js +34 -3
- package/dist/cjs/api/meta/initialize.js.map +1 -1
- package/dist/cjs/api/meta/types.js.map +1 -1
- package/dist/cjs/config/types.js.map +1 -1
- package/dist/cjs/index.js +6 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/metas/index.js.map +1 -1
- package/dist/cjs/metas/types.js.map +1 -1
- package/dist/cjs/semantic.js +2 -1
- package/dist/cjs/semantic.js.map +1 -1
- package/dist/cjs/utils/index.js +5 -1
- package/dist/cjs/utils/index.js.map +1 -1
- package/dist/cjs/utils/is.js +14 -1
- package/dist/cjs/utils/is.js.map +1 -1
- package/dist/cjs/utils/json.js +22 -0
- package/dist/cjs/utils/json.js.map +1 -0
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/version.js.map +1 -1
- package/dist/esm/api/exceptions/const.js +11 -0
- package/dist/esm/api/exceptions/const.js.map +1 -1
- package/dist/esm/api/exceptions/index.js +1 -1
- package/dist/esm/api/exceptions/index.js.map +1 -1
- package/dist/esm/api/index.js +1 -1
- package/dist/esm/api/index.js.map +1 -1
- package/dist/esm/api/meta/initialize.js +23 -3
- package/dist/esm/api/meta/initialize.js.map +1 -1
- package/dist/esm/api/meta/types.js.map +1 -1
- package/dist/esm/config/types.js.map +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/metas/index.js.map +1 -1
- package/dist/esm/metas/types.js.map +1 -1
- package/dist/esm/semantic.js +1 -0
- package/dist/esm/semantic.js.map +1 -1
- package/dist/esm/utils/index.js +2 -1
- package/dist/esm/utils/index.js.map +1 -1
- package/dist/esm/utils/is.js +12 -0
- package/dist/esm/utils/is.js.map +1 -1
- package/dist/esm/utils/json.js +16 -0
- package/dist/esm/utils/json.js.map +1 -0
- package/dist/esm/version.js +1 -1
- package/dist/esm/version.js.map +1 -1
- package/dist/spec/core/src/api/exceptions/const.js +13 -1
- package/dist/spec/core/src/api/exceptions/const.js.map +1 -1
- package/dist/spec/core/src/api/exceptions/index.js +2 -1
- package/dist/spec/core/src/api/exceptions/index.js.map +1 -1
- package/dist/spec/core/src/api/index.js +2 -1
- package/dist/spec/core/src/api/index.js.map +1 -1
- package/dist/spec/core/src/api/meta/initialize.js +34 -3
- package/dist/spec/core/src/api/meta/initialize.js.map +1 -1
- package/dist/spec/core/src/api/meta/initilialize.test.js +90 -0
- package/dist/spec/core/src/api/meta/initilialize.test.js.map +1 -0
- package/dist/spec/core/src/api/meta/types.js.map +1 -1
- package/dist/spec/core/src/config/types.js.map +1 -1
- package/dist/spec/core/src/index.js +6 -2
- package/dist/spec/core/src/index.js.map +1 -1
- package/dist/spec/core/src/metas/index.js.map +1 -1
- package/dist/spec/core/src/metas/types.js.map +1 -1
- package/dist/spec/core/src/semantic.js +2 -1
- package/dist/spec/core/src/semantic.js.map +1 -1
- package/dist/spec/core/src/utils/index.js +5 -1
- package/dist/spec/core/src/utils/index.js.map +1 -1
- package/dist/spec/core/src/utils/is.js +14 -1
- package/dist/spec/core/src/utils/is.js.map +1 -1
- package/dist/spec/core/src/utils/is.test.js +21 -0
- package/dist/spec/core/src/utils/is.test.js.map +1 -0
- package/dist/spec/core/src/utils/json.js +22 -0
- package/dist/spec/core/src/utils/json.js.map +1 -0
- package/dist/spec/core/src/utils/json.test.js +17 -0
- package/dist/spec/core/src/utils/json.test.js.map +1 -0
- package/dist/spec/core/src/version.js +1 -1
- package/dist/spec/core/src/version.js.map +1 -1
- package/dist/types/api/exceptions/const.d.ts +1 -0
- package/dist/types/api/exceptions/index.d.ts +1 -1
- package/dist/types/api/index.d.ts +1 -1
- package/dist/types/api/meta/types.d.ts +13 -3
- package/dist/types/config/types.d.ts +21 -1
- package/dist/types/core/src/api/exceptions/const.d.ts +1 -0
- package/dist/types/core/src/api/exceptions/index.d.ts +1 -1
- package/dist/types/core/src/api/index.d.ts +1 -1
- package/dist/types/core/src/api/meta/initilialize.test.d.ts +1 -0
- package/dist/types/core/src/api/meta/types.d.ts +13 -3
- package/dist/types/core/src/config/types.d.ts +21 -1
- package/dist/types/core/src/index.d.ts +3 -3
- package/dist/types/core/src/metas/index.d.ts +1 -1
- package/dist/types/core/src/metas/types.d.ts +7 -0
- package/dist/types/core/src/semantic.d.ts +1 -0
- package/dist/types/core/src/testUtils/mockTransport.d.ts +1 -1
- package/dist/types/core/src/utils/index.d.ts +2 -1
- package/dist/types/core/src/utils/is.d.ts +1 -0
- package/dist/types/core/src/utils/is.test.d.ts +1 -0
- package/dist/types/core/src/utils/json.d.ts +2 -0
- package/dist/types/core/src/utils/json.test.d.ts +1 -0
- package/dist/types/core/src/version.d.ts +1 -1
- package/dist/types/index.d.ts +3 -3
- package/dist/types/metas/index.d.ts +1 -1
- package/dist/types/metas/types.d.ts +7 -0
- package/dist/types/semantic.d.ts +1 -0
- package/dist/types/testUtils/mockTransport.d.ts +1 -1
- package/dist/types/utils/index.d.ts +2 -1
- package/dist/types/utils/is.d.ts +1 -0
- package/dist/types/utils/json.d.ts +2 -0
- package/dist/types/version.d.ts +1 -1
- package/package.json +5 -2
|
@@ -1,10 +1,20 @@
|
|
|
1
|
-
import type { MetaSession, MetaUser, MetaView } from '../../metas';
|
|
1
|
+
import type { MetaOverrides, MetaPage, MetaSession, MetaUser, MetaView } from '../../metas';
|
|
2
2
|
export interface MetaAPI {
|
|
3
3
|
setUser: (user?: MetaUser | undefined) => void;
|
|
4
4
|
resetUser: () => void;
|
|
5
|
-
setSession: (session?: MetaSession | undefined
|
|
5
|
+
setSession: (session?: MetaSession | undefined, options?: {
|
|
6
|
+
overrides: MetaOverrides;
|
|
7
|
+
}) => void;
|
|
6
8
|
resetSession: () => void;
|
|
7
9
|
getSession: () => MetaSession | undefined;
|
|
8
|
-
setView: (view?: MetaView | undefined
|
|
10
|
+
setView: (view?: MetaView | undefined, options?: {
|
|
11
|
+
overrides: MetaOverrides;
|
|
12
|
+
}) => void;
|
|
9
13
|
getView: () => MetaView | undefined;
|
|
14
|
+
/**
|
|
15
|
+
* If a string is provided, it will be used as the page id.
|
|
16
|
+
* @returns
|
|
17
|
+
*/
|
|
18
|
+
setPage: (page?: MetaPage | string | undefined) => void;
|
|
19
|
+
getPage: () => MetaPage | undefined;
|
|
10
20
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { APIEvent, LogArgsSerializer, StacktraceParser } from '../api';
|
|
2
2
|
import type { Instrumentation } from '../instrumentations';
|
|
3
3
|
import type { InternalLoggerLevel } from '../internalLogger';
|
|
4
|
-
import type { Meta, MetaApp, MetaItem, MetaSession, MetaUser, MetaView } from '../metas';
|
|
4
|
+
import type { Meta, MetaApp, MetaItem, MetaPage, MetaSession, MetaUser, MetaView } from '../metas';
|
|
5
5
|
import type { BatchExecutorOptions, BeforeSendHook, Transport } from '../transports';
|
|
6
6
|
import type { UnpatchedConsole } from '../unpatchedConsole';
|
|
7
7
|
import type { LogLevel } from '../utils';
|
|
@@ -151,6 +151,26 @@ export interface Config<P = APIEvent> {
|
|
|
151
151
|
*/
|
|
152
152
|
disabledLevels?: LogLevel[];
|
|
153
153
|
consoleErrorAsLog?: boolean;
|
|
154
|
+
/**
|
|
155
|
+
* If true, use the default Faro error serializer for console.error calls. If false, simply call toString() on the error arguments.
|
|
156
|
+
* If enabled, payloads containing serialized errors may become very large. If left disabled, some error details may be lost.
|
|
157
|
+
* (default: false)
|
|
158
|
+
*/
|
|
159
|
+
serializeErrors?: boolean;
|
|
160
|
+
/**
|
|
161
|
+
* Custom function to serialize Error arguments
|
|
162
|
+
*/
|
|
163
|
+
errorSerializer?: LogArgsSerializer;
|
|
164
|
+
};
|
|
165
|
+
pageTracking?: {
|
|
166
|
+
/**
|
|
167
|
+
* The page meta for initial page settings
|
|
168
|
+
*/
|
|
169
|
+
page?: MetaPage;
|
|
170
|
+
/**
|
|
171
|
+
* Allows to provide a template for the page id
|
|
172
|
+
*/
|
|
173
|
+
generatePageId?: (location: Location) => string;
|
|
154
174
|
};
|
|
155
175
|
}
|
|
156
176
|
export type Patterns = Array<string | RegExp>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { defaultExceptionType } from './const';
|
|
1
|
+
export { defaultExceptionType, defaultErrorArgsSerializer } from './const';
|
|
2
2
|
export { initializeExceptionsAPI } from './initialize';
|
|
3
3
|
export type { ExceptionEvent, ExceptionStackFrame, ExceptionsAPI, ExtendedError, PushErrorOptions, Stacktrace, StacktraceParser, ErrorWithIndexProperties, } from './types';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export { initializeAPI } from './initialize';
|
|
2
2
|
export type { API, APIEvent } from './types';
|
|
3
3
|
export type { EventAttributes, EventEvent, EventsAPI, PushEventOptions } from './events';
|
|
4
|
-
export { defaultExceptionType } from './exceptions';
|
|
4
|
+
export { defaultExceptionType, defaultErrorArgsSerializer } from './exceptions';
|
|
5
5
|
export type { ExceptionEvent, ExceptionStackFrame, ExceptionsAPI, ExtendedError, PushErrorOptions, Stacktrace, StacktraceParser, } from './exceptions';
|
|
6
6
|
export { defaultLogArgsSerializer } from './logs';
|
|
7
7
|
export type { LogContext, LogEvent, LogArgsSerializer, LogsAPI, PushLogOptions } from './logs';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,10 +1,20 @@
|
|
|
1
|
-
import type { MetaSession, MetaUser, MetaView } from '../../metas';
|
|
1
|
+
import type { MetaOverrides, MetaPage, MetaSession, MetaUser, MetaView } from '../../metas';
|
|
2
2
|
export interface MetaAPI {
|
|
3
3
|
setUser: (user?: MetaUser | undefined) => void;
|
|
4
4
|
resetUser: () => void;
|
|
5
|
-
setSession: (session?: MetaSession | undefined
|
|
5
|
+
setSession: (session?: MetaSession | undefined, options?: {
|
|
6
|
+
overrides: MetaOverrides;
|
|
7
|
+
}) => void;
|
|
6
8
|
resetSession: () => void;
|
|
7
9
|
getSession: () => MetaSession | undefined;
|
|
8
|
-
setView: (view?: MetaView | undefined
|
|
10
|
+
setView: (view?: MetaView | undefined, options?: {
|
|
11
|
+
overrides: MetaOverrides;
|
|
12
|
+
}) => void;
|
|
9
13
|
getView: () => MetaView | undefined;
|
|
14
|
+
/**
|
|
15
|
+
* If a string is provided, it will be used as the page id.
|
|
16
|
+
* @returns
|
|
17
|
+
*/
|
|
18
|
+
setPage: (page?: MetaPage | string | undefined) => void;
|
|
19
|
+
getPage: () => MetaPage | undefined;
|
|
10
20
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { APIEvent, LogArgsSerializer, StacktraceParser } from '../api';
|
|
2
2
|
import type { Instrumentation } from '../instrumentations';
|
|
3
3
|
import type { InternalLoggerLevel } from '../internalLogger';
|
|
4
|
-
import type { Meta, MetaApp, MetaItem, MetaSession, MetaUser, MetaView } from '../metas';
|
|
4
|
+
import type { Meta, MetaApp, MetaItem, MetaPage, MetaSession, MetaUser, MetaView } from '../metas';
|
|
5
5
|
import type { BatchExecutorOptions, BeforeSendHook, Transport } from '../transports';
|
|
6
6
|
import type { UnpatchedConsole } from '../unpatchedConsole';
|
|
7
7
|
import type { LogLevel } from '../utils';
|
|
@@ -151,6 +151,26 @@ export interface Config<P = APIEvent> {
|
|
|
151
151
|
*/
|
|
152
152
|
disabledLevels?: LogLevel[];
|
|
153
153
|
consoleErrorAsLog?: boolean;
|
|
154
|
+
/**
|
|
155
|
+
* If true, use the default Faro error serializer for console.error calls. If false, simply call toString() on the error arguments.
|
|
156
|
+
* If enabled, payloads containing serialized errors may become very large. If left disabled, some error details may be lost.
|
|
157
|
+
* (default: false)
|
|
158
|
+
*/
|
|
159
|
+
serializeErrors?: boolean;
|
|
160
|
+
/**
|
|
161
|
+
* Custom function to serialize Error arguments
|
|
162
|
+
*/
|
|
163
|
+
errorSerializer?: LogArgsSerializer;
|
|
164
|
+
};
|
|
165
|
+
pageTracking?: {
|
|
166
|
+
/**
|
|
167
|
+
* The page meta for initial page settings
|
|
168
|
+
*/
|
|
169
|
+
page?: MetaPage;
|
|
170
|
+
/**
|
|
171
|
+
* Allows to provide a template for the page id
|
|
172
|
+
*/
|
|
173
|
+
generatePageId?: (location: Location) => string;
|
|
154
174
|
};
|
|
155
175
|
}
|
|
156
176
|
export type Patterns = Array<string | RegExp>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { defaultExceptionType, defaultLogArgsSerializer } from './api';
|
|
1
|
+
export { defaultExceptionType, defaultLogArgsSerializer, defaultErrorArgsSerializer } from './api';
|
|
2
2
|
export type { API, APIEvent, EventAttributes, EventEvent, EventsAPI, ExceptionEvent, ExceptionStackFrame, ExceptionsAPI, ExtendedError, LogArgsSerializer, LogContext, LogEvent, LogsAPI, MeasurementEvent, MeasurementsAPI, MetaAPI, OTELApi, PushErrorOptions, PushEventOptions, PushLogOptions, PushMeasurementOptions, Stacktrace, StacktraceParser, TraceContext, TraceEvent, TracesAPI, } from './api';
|
|
3
3
|
export { BaseExtension } from './extensions';
|
|
4
4
|
export type { Extension } from './extensions';
|
|
@@ -11,7 +11,7 @@ export { BaseInstrumentation } from './instrumentations';
|
|
|
11
11
|
export type { Instrumentation, Instrumentations } from './instrumentations';
|
|
12
12
|
export { createInternalLogger, defaultInternalLoggerLevel, InternalLoggerLevel } from './internalLogger';
|
|
13
13
|
export type { InternalLogger } from './internalLogger';
|
|
14
|
-
export type { Meta, MetaApp, MetaAttributes, MetaBrowser, MetaGetter, MetaItem, MetaPage, Metas, MetaSDK, MetaSDKIntegration, MetaSession, MetaUser, MetaView, } from './metas';
|
|
14
|
+
export type { Meta, MetaApp, MetaAttributes, MetaBrowser, MetaGetter, MetaItem, MetaPage, Metas, MetaSDK, MetaSDKIntegration, MetaSession, MetaUser, MetaView, MetaOverrides, } from './metas';
|
|
15
15
|
export { faro, getInternalFaroFromGlobalObject, internalGlobalObjectKey, isInternalFaroOnGlobalObject, setInternalFaroOnGlobalObject, } from './sdk';
|
|
16
16
|
export type { Faro } from './sdk';
|
|
17
17
|
export * from './semantic';
|
|
@@ -19,7 +19,7 @@ export { BaseTransport, getTransportBody, TransportItemType, transportItemTypeTo
|
|
|
19
19
|
export type { BeforeSendHook, SendFn, Transport, TransportBody, TransportItem, TransportItemPayload, Transports, } from './transports';
|
|
20
20
|
export { defaultUnpatchedConsole } from './unpatchedConsole';
|
|
21
21
|
export type { UnpatchedConsole } from './unpatchedConsole';
|
|
22
|
-
export { allLogLevels, createPromiseBuffer, deepEqual, defaultLogLevel, genShortID, getCurrentTimestamp, isArray, isBoolean, isDomError, isDomException, isElement, isElementDefined, isError, isErrorDefined, isErrorEvent, isEvent, isEventDefined, isFunction, isInstanceOf, isInt, isMap, isMapDefined, isNull, isNumber, isObject, isPrimitive, isRegExp, isString, isSymbol, isSyntheticEvent, isThenable, isToString, isTypeof, isUndefined, LogLevel, noop, dateNow, } from './utils';
|
|
22
|
+
export { allLogLevels, createPromiseBuffer, deepEqual, defaultLogLevel, genShortID, getCurrentTimestamp, isArray, isBoolean, isDomError, isDomException, isElement, isElementDefined, isError, isErrorDefined, isErrorEvent, isEvent, isEventDefined, isFunction, isInstanceOf, isInt, isMap, isMapDefined, isNull, isNumber, isObject, isPrimitive, isRegExp, isString, isSymbol, isSyntheticEvent, isThenable, isToString, isTypeof, isUndefined, LogLevel, noop, dateNow, isEmpty, getCircularDependencyReplacer, stringifyExternalJson, } from './utils';
|
|
23
23
|
export type { BaseObject, BaseObjectKey, BaseObjectPrimitiveValue, BaseObjectValue, BufferItem, PromiseBuffer, PromiseBufferOptions, PromiseProducer, } from './utils';
|
|
24
24
|
export { VERSION } from './version';
|
|
25
25
|
export { unknownString } from './consts';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { initializeMetas } from './initialize';
|
|
2
2
|
export { registerInitialMetas } from './registerInitial';
|
|
3
|
-
export type { Meta, MetaApp, MetaAttributes, MetaBrowser, MetaGetter, MetaItem, MetaK6, MetaPage, MetaSDK, MetaSDKIntegration, MetaSession, MetaUser, MetaView, Metas, } from './types';
|
|
3
|
+
export type { Meta, MetaApp, MetaAttributes, MetaBrowser, MetaGetter, MetaItem, MetaK6, MetaPage, MetaSDK, MetaSDKIntegration, MetaSession, MetaUser, MetaView, Metas, MetaOverrides, } from './types';
|
|
@@ -35,6 +35,7 @@ export interface MetaUser {
|
|
|
35
35
|
export interface MetaSession {
|
|
36
36
|
id?: string;
|
|
37
37
|
attributes?: MetaAttributes;
|
|
38
|
+
overrides?: MetaOverrides;
|
|
38
39
|
}
|
|
39
40
|
export interface MetaPage {
|
|
40
41
|
id?: string;
|
|
@@ -73,4 +74,10 @@ export interface Meta {
|
|
|
73
74
|
view?: MetaView;
|
|
74
75
|
k6?: MetaK6;
|
|
75
76
|
}
|
|
77
|
+
/**
|
|
78
|
+
* Overrides are instructions that allow the receiver to override certain properties.
|
|
79
|
+
*/
|
|
80
|
+
export type MetaOverrides = {
|
|
81
|
+
serviceName?: string;
|
|
82
|
+
};
|
|
76
83
|
export {};
|
|
@@ -18,4 +18,5 @@ export declare const EVENT_VIEW_CHANGED = "view_changed";
|
|
|
18
18
|
export declare const EVENT_SESSION_START = "session_start";
|
|
19
19
|
export declare const EVENT_SESSION_RESUME = "session_resume";
|
|
20
20
|
export declare const EVENT_SESSION_EXTEND = "session_extend";
|
|
21
|
+
export declare const EVENT_OVERRIDES_SERVICE_NAME = "service_name_override";
|
|
21
22
|
export declare const EVENT_ROUTE_CHANGE = "route_change";
|
|
@@ -4,7 +4,7 @@ import type { Transport, TransportItem } from '../transports';
|
|
|
4
4
|
export declare class MockTransport extends BaseTransport implements Transport {
|
|
5
5
|
private ignoreURLs;
|
|
6
6
|
readonly name = "@grafana/transport-mock";
|
|
7
|
-
readonly version = "1.
|
|
7
|
+
readonly version = "1.13.0";
|
|
8
8
|
items: TransportItem[];
|
|
9
9
|
constructor(ignoreURLs?: Patterns);
|
|
10
10
|
send(items: TransportItem[]): void | Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export type { BaseObject, BaseObjectKey, BaseObjectPrimitiveValue, BaseObjectValue } from './baseObject';
|
|
2
2
|
export { deepEqual } from './deepEqual';
|
|
3
3
|
export { getCurrentTimestamp } from './date';
|
|
4
|
-
export { isArray, isBoolean, isDomError, isDomException, isElement, isElementDefined, isError, isErrorDefined, isErrorEvent, isEvent, isEventDefined, isFunction, isInstanceOf, isInt, isMap, isMapDefined, isNull, isNumber, isObject, isPrimitive, isRegExp, isString, isSymbol, isSyntheticEvent, isThenable, isToString, isTypeof, isUndefined, } from './is';
|
|
4
|
+
export { isArray, isBoolean, isDomError, isDomException, isElement, isElementDefined, isError, isErrorDefined, isErrorEvent, isEvent, isEventDefined, isFunction, isInstanceOf, isInt, isMap, isMapDefined, isNull, isNumber, isObject, isPrimitive, isRegExp, isString, isSymbol, isSyntheticEvent, isThenable, isToString, isTypeof, isUndefined, isEmpty, } from './is';
|
|
5
5
|
export type { IsFnHelper } from './is';
|
|
6
6
|
export { allLogLevels, defaultLogLevel, LogLevel } from './logLevels';
|
|
7
7
|
export { noop } from './noop';
|
|
@@ -10,3 +10,4 @@ export type { BufferItem, PromiseBuffer, PromiseBufferOptions, PromiseProducer }
|
|
|
10
10
|
export { genShortID } from './shortId';
|
|
11
11
|
export { getBundleId } from './sourceMaps';
|
|
12
12
|
export { dateNow } from './date';
|
|
13
|
+
export { getCircularDependencyReplacer, stringifyExternalJson } from './json';
|
|
@@ -29,3 +29,4 @@ export declare const isElement: IsFnHelper<Element>;
|
|
|
29
29
|
export declare const isMapDefined: boolean;
|
|
30
30
|
export declare const isMap: IsFnHelper<Map<any, any>>;
|
|
31
31
|
export declare const isSyntheticEvent: IsFnHelper<Event>;
|
|
32
|
+
export declare function isEmpty(value: any): boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "1.
|
|
1
|
+
export declare const VERSION = "1.13.0";
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { defaultExceptionType, defaultLogArgsSerializer } from './api';
|
|
1
|
+
export { defaultExceptionType, defaultLogArgsSerializer, defaultErrorArgsSerializer } from './api';
|
|
2
2
|
export type { API, APIEvent, EventAttributes, EventEvent, EventsAPI, ExceptionEvent, ExceptionStackFrame, ExceptionsAPI, ExtendedError, LogArgsSerializer, LogContext, LogEvent, LogsAPI, MeasurementEvent, MeasurementsAPI, MetaAPI, OTELApi, PushErrorOptions, PushEventOptions, PushLogOptions, PushMeasurementOptions, Stacktrace, StacktraceParser, TraceContext, TraceEvent, TracesAPI, } from './api';
|
|
3
3
|
export { BaseExtension } from './extensions';
|
|
4
4
|
export type { Extension } from './extensions';
|
|
@@ -11,7 +11,7 @@ export { BaseInstrumentation } from './instrumentations';
|
|
|
11
11
|
export type { Instrumentation, Instrumentations } from './instrumentations';
|
|
12
12
|
export { createInternalLogger, defaultInternalLoggerLevel, InternalLoggerLevel } from './internalLogger';
|
|
13
13
|
export type { InternalLogger } from './internalLogger';
|
|
14
|
-
export type { Meta, MetaApp, MetaAttributes, MetaBrowser, MetaGetter, MetaItem, MetaPage, Metas, MetaSDK, MetaSDKIntegration, MetaSession, MetaUser, MetaView, } from './metas';
|
|
14
|
+
export type { Meta, MetaApp, MetaAttributes, MetaBrowser, MetaGetter, MetaItem, MetaPage, Metas, MetaSDK, MetaSDKIntegration, MetaSession, MetaUser, MetaView, MetaOverrides, } from './metas';
|
|
15
15
|
export { faro, getInternalFaroFromGlobalObject, internalGlobalObjectKey, isInternalFaroOnGlobalObject, setInternalFaroOnGlobalObject, } from './sdk';
|
|
16
16
|
export type { Faro } from './sdk';
|
|
17
17
|
export * from './semantic';
|
|
@@ -19,7 +19,7 @@ export { BaseTransport, getTransportBody, TransportItemType, transportItemTypeTo
|
|
|
19
19
|
export type { BeforeSendHook, SendFn, Transport, TransportBody, TransportItem, TransportItemPayload, Transports, } from './transports';
|
|
20
20
|
export { defaultUnpatchedConsole } from './unpatchedConsole';
|
|
21
21
|
export type { UnpatchedConsole } from './unpatchedConsole';
|
|
22
|
-
export { allLogLevels, createPromiseBuffer, deepEqual, defaultLogLevel, genShortID, getCurrentTimestamp, isArray, isBoolean, isDomError, isDomException, isElement, isElementDefined, isError, isErrorDefined, isErrorEvent, isEvent, isEventDefined, isFunction, isInstanceOf, isInt, isMap, isMapDefined, isNull, isNumber, isObject, isPrimitive, isRegExp, isString, isSymbol, isSyntheticEvent, isThenable, isToString, isTypeof, isUndefined, LogLevel, noop, dateNow, } from './utils';
|
|
22
|
+
export { allLogLevels, createPromiseBuffer, deepEqual, defaultLogLevel, genShortID, getCurrentTimestamp, isArray, isBoolean, isDomError, isDomException, isElement, isElementDefined, isError, isErrorDefined, isErrorEvent, isEvent, isEventDefined, isFunction, isInstanceOf, isInt, isMap, isMapDefined, isNull, isNumber, isObject, isPrimitive, isRegExp, isString, isSymbol, isSyntheticEvent, isThenable, isToString, isTypeof, isUndefined, LogLevel, noop, dateNow, isEmpty, getCircularDependencyReplacer, stringifyExternalJson, } from './utils';
|
|
23
23
|
export type { BaseObject, BaseObjectKey, BaseObjectPrimitiveValue, BaseObjectValue, BufferItem, PromiseBuffer, PromiseBufferOptions, PromiseProducer, } from './utils';
|
|
24
24
|
export { VERSION } from './version';
|
|
25
25
|
export { unknownString } from './consts';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { initializeMetas } from './initialize';
|
|
2
2
|
export { registerInitialMetas } from './registerInitial';
|
|
3
|
-
export type { Meta, MetaApp, MetaAttributes, MetaBrowser, MetaGetter, MetaItem, MetaK6, MetaPage, MetaSDK, MetaSDKIntegration, MetaSession, MetaUser, MetaView, Metas, } from './types';
|
|
3
|
+
export type { Meta, MetaApp, MetaAttributes, MetaBrowser, MetaGetter, MetaItem, MetaK6, MetaPage, MetaSDK, MetaSDKIntegration, MetaSession, MetaUser, MetaView, Metas, MetaOverrides, } from './types';
|
|
@@ -35,6 +35,7 @@ export interface MetaUser {
|
|
|
35
35
|
export interface MetaSession {
|
|
36
36
|
id?: string;
|
|
37
37
|
attributes?: MetaAttributes;
|
|
38
|
+
overrides?: MetaOverrides;
|
|
38
39
|
}
|
|
39
40
|
export interface MetaPage {
|
|
40
41
|
id?: string;
|
|
@@ -73,4 +74,10 @@ export interface Meta {
|
|
|
73
74
|
view?: MetaView;
|
|
74
75
|
k6?: MetaK6;
|
|
75
76
|
}
|
|
77
|
+
/**
|
|
78
|
+
* Overrides are instructions that allow the receiver to override certain properties.
|
|
79
|
+
*/
|
|
80
|
+
export type MetaOverrides = {
|
|
81
|
+
serviceName?: string;
|
|
82
|
+
};
|
|
76
83
|
export {};
|
package/dist/types/semantic.d.ts
CHANGED
|
@@ -18,4 +18,5 @@ export declare const EVENT_VIEW_CHANGED = "view_changed";
|
|
|
18
18
|
export declare const EVENT_SESSION_START = "session_start";
|
|
19
19
|
export declare const EVENT_SESSION_RESUME = "session_resume";
|
|
20
20
|
export declare const EVENT_SESSION_EXTEND = "session_extend";
|
|
21
|
+
export declare const EVENT_OVERRIDES_SERVICE_NAME = "service_name_override";
|
|
21
22
|
export declare const EVENT_ROUTE_CHANGE = "route_change";
|
|
@@ -4,7 +4,7 @@ import type { Transport, TransportItem } from '../transports';
|
|
|
4
4
|
export declare class MockTransport extends BaseTransport implements Transport {
|
|
5
5
|
private ignoreURLs;
|
|
6
6
|
readonly name = "@grafana/transport-mock";
|
|
7
|
-
readonly version = "1.
|
|
7
|
+
readonly version = "1.13.0";
|
|
8
8
|
items: TransportItem[];
|
|
9
9
|
constructor(ignoreURLs?: Patterns);
|
|
10
10
|
send(items: TransportItem[]): void | Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export type { BaseObject, BaseObjectKey, BaseObjectPrimitiveValue, BaseObjectValue } from './baseObject';
|
|
2
2
|
export { deepEqual } from './deepEqual';
|
|
3
3
|
export { getCurrentTimestamp } from './date';
|
|
4
|
-
export { isArray, isBoolean, isDomError, isDomException, isElement, isElementDefined, isError, isErrorDefined, isErrorEvent, isEvent, isEventDefined, isFunction, isInstanceOf, isInt, isMap, isMapDefined, isNull, isNumber, isObject, isPrimitive, isRegExp, isString, isSymbol, isSyntheticEvent, isThenable, isToString, isTypeof, isUndefined, } from './is';
|
|
4
|
+
export { isArray, isBoolean, isDomError, isDomException, isElement, isElementDefined, isError, isErrorDefined, isErrorEvent, isEvent, isEventDefined, isFunction, isInstanceOf, isInt, isMap, isMapDefined, isNull, isNumber, isObject, isPrimitive, isRegExp, isString, isSymbol, isSyntheticEvent, isThenable, isToString, isTypeof, isUndefined, isEmpty, } from './is';
|
|
5
5
|
export type { IsFnHelper } from './is';
|
|
6
6
|
export { allLogLevels, defaultLogLevel, LogLevel } from './logLevels';
|
|
7
7
|
export { noop } from './noop';
|
|
@@ -10,3 +10,4 @@ export type { BufferItem, PromiseBuffer, PromiseBufferOptions, PromiseProducer }
|
|
|
10
10
|
export { genShortID } from './shortId';
|
|
11
11
|
export { getBundleId } from './sourceMaps';
|
|
12
12
|
export { dateNow } from './date';
|
|
13
|
+
export { getCircularDependencyReplacer, stringifyExternalJson } from './json';
|
package/dist/types/utils/is.d.ts
CHANGED
|
@@ -29,3 +29,4 @@ export declare const isElement: IsFnHelper<Element>;
|
|
|
29
29
|
export declare const isMapDefined: boolean;
|
|
30
30
|
export declare const isMap: IsFnHelper<Map<any, any>>;
|
|
31
31
|
export declare const isSyntheticEvent: IsFnHelper<Event>;
|
|
32
|
+
export declare function isEmpty(value: any): boolean;
|
package/dist/types/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "1.
|
|
1
|
+
export declare const VERSION = "1.13.0";
|
package/package.json
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@grafana/faro-core",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.13.0",
|
|
4
4
|
"description": "Core package of Faro.",
|
|
5
|
+
"engines": {
|
|
6
|
+
"node": ">=18.0.0"
|
|
7
|
+
},
|
|
5
8
|
"keywords": [
|
|
6
9
|
"observability",
|
|
7
10
|
"apm",
|
|
@@ -60,5 +63,5 @@
|
|
|
60
63
|
"publishConfig": {
|
|
61
64
|
"access": "public"
|
|
62
65
|
},
|
|
63
|
-
"gitHead": "
|
|
66
|
+
"gitHead": "6cd423ffab2f4218c81d624577958d3140a438ba"
|
|
64
67
|
}
|