@navikt/apm 0.0.0-stage → 0.7.3

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.
Files changed (103) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +527 -2
  3. package/dist/api.d.ts +108 -0
  4. package/dist/api.d.ts.map +1 -0
  5. package/dist/api.js +220 -0
  6. package/dist/api.js.map +1 -0
  7. package/dist/config.d.ts +150 -0
  8. package/dist/config.d.ts.map +1 -0
  9. package/dist/config.js +268 -0
  10. package/dist/config.js.map +1 -0
  11. package/dist/console.d.ts +28 -0
  12. package/dist/console.d.ts.map +1 -0
  13. package/dist/console.js +71 -0
  14. package/dist/console.js.map +1 -0
  15. package/dist/errors.d.ts +40 -0
  16. package/dist/errors.d.ts.map +1 -0
  17. package/dist/errors.js +177 -0
  18. package/dist/errors.js.map +1 -0
  19. package/dist/feedback.d.ts +42 -0
  20. package/dist/feedback.d.ts.map +1 -0
  21. package/dist/feedback.js +72 -0
  22. package/dist/feedback.js.map +1 -0
  23. package/dist/index.d.ts +144 -0
  24. package/dist/index.d.ts.map +1 -0
  25. package/dist/index.js +249 -0
  26. package/dist/index.js.map +1 -0
  27. package/dist/internal.d.ts +47 -0
  28. package/dist/internal.d.ts.map +1 -0
  29. package/dist/internal.js +129 -0
  30. package/dist/internal.js.map +1 -0
  31. package/dist/metaTags.d.ts +34 -0
  32. package/dist/metaTags.d.ts.map +1 -0
  33. package/dist/metaTags.js +76 -0
  34. package/dist/metaTags.js.map +1 -0
  35. package/dist/react/ErrorBoundary.d.ts +59 -0
  36. package/dist/react/ErrorBoundary.d.ts.map +1 -0
  37. package/dist/react/ErrorBoundary.js +92 -0
  38. package/dist/react/ErrorBoundary.js.map +1 -0
  39. package/dist/react/NaisMetaTags.d.ts +25 -0
  40. package/dist/react/NaisMetaTags.d.ts.map +1 -0
  41. package/dist/react/NaisMetaTags.js +6 -0
  42. package/dist/react/NaisMetaTags.js.map +1 -0
  43. package/dist/react/index.d.ts +17 -0
  44. package/dist/react/index.d.ts.map +1 -0
  45. package/dist/react/index.js +14 -0
  46. package/dist/react/index.js.map +1 -0
  47. package/dist/react/nextClient.d.ts +25 -0
  48. package/dist/react/nextClient.d.ts.map +1 -0
  49. package/dist/react/nextClient.js +29 -0
  50. package/dist/react/nextClient.js.map +1 -0
  51. package/dist/react/routing.d.ts +56 -0
  52. package/dist/react/routing.d.ts.map +1 -0
  53. package/dist/react/routing.js +89 -0
  54. package/dist/react/routing.js.map +1 -0
  55. package/dist/replay/constants.d.ts +26 -0
  56. package/dist/replay/constants.d.ts.map +1 -0
  57. package/dist/replay/constants.js +24 -0
  58. package/dist/replay/constants.js.map +1 -0
  59. package/dist/replay/events.d.ts +74 -0
  60. package/dist/replay/events.d.ts.map +1 -0
  61. package/dist/replay/events.js +258 -0
  62. package/dist/replay/events.js.map +1 -0
  63. package/dist/replay/hash.d.ts +8 -0
  64. package/dist/replay/hash.d.ts.map +1 -0
  65. package/dist/replay/hash.js +14 -0
  66. package/dist/replay/hash.js.map +1 -0
  67. package/dist/replay/masking.d.ts +89 -0
  68. package/dist/replay/masking.d.ts.map +1 -0
  69. package/dist/replay/masking.js +199 -0
  70. package/dist/replay/masking.js.map +1 -0
  71. package/dist/replay/options.d.ts +52 -0
  72. package/dist/replay/options.d.ts.map +1 -0
  73. package/dist/replay/options.js +66 -0
  74. package/dist/replay/options.js.map +1 -0
  75. package/dist/replay/recording.d.ts +60 -0
  76. package/dist/replay/recording.d.ts.map +1 -0
  77. package/dist/replay/recording.js +120 -0
  78. package/dist/replay/recording.js.map +1 -0
  79. package/dist/replay/snapshot.d.ts +41 -0
  80. package/dist/replay/snapshot.d.ts.map +1 -0
  81. package/dist/replay/snapshot.js +97 -0
  82. package/dist/replay/snapshot.js.map +1 -0
  83. package/dist/replay/transport.d.ts +82 -0
  84. package/dist/replay/transport.d.ts.map +1 -0
  85. package/dist/replay/transport.js +188 -0
  86. package/dist/replay/transport.js.map +1 -0
  87. package/dist/scrub.d.ts +69 -0
  88. package/dist/scrub.d.ts.map +1 -0
  89. package/dist/scrub.js +317 -0
  90. package/dist/scrub.js.map +1 -0
  91. package/dist/serialize.d.ts +15 -0
  92. package/dist/serialize.d.ts.map +1 -0
  93. package/dist/serialize.js +68 -0
  94. package/dist/serialize.js.map +1 -0
  95. package/dist/tracing.d.ts +37 -0
  96. package/dist/tracing.d.ts.map +1 -0
  97. package/dist/tracing.js +70 -0
  98. package/dist/tracing.js.map +1 -0
  99. package/dist/version.d.ts +3 -0
  100. package/dist/version.d.ts.map +1 -0
  101. package/dist/version.js +3 -0
  102. package/dist/version.js.map +1 -0
  103. package/package.json +94 -4
@@ -0,0 +1,92 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ /**
3
+ * React error boundary for @nais/apm (nais/grafana-apm-app#79).
4
+ *
5
+ * Why hand-rolled instead of wrapping faro-react's `FaroErrorBoundary`:
6
+ * `FaroErrorBoundary.componentDidCatch` unconditionally calls `api.pushError`
7
+ * itself. Routing a caught error through our `captureException` (to get the
8
+ * SDK's fingerprint/context pipeline) on top of that would report the SAME
9
+ * error twice. This boundary therefore owns the lifecycle and reports EXACTLY
10
+ * ONCE through `captureException`, so a render error gets our fingerprint and
11
+ * global context — and, as a bonus, the React entry stays free of faro-react's
12
+ * non-tree-shakeable barrel.
13
+ */
14
+ import { Component, isValidElement } from 'react';
15
+ import { captureException } from '../api.js';
16
+ import { markErrorCaptured } from '../internal.js';
17
+ const defaultFallback = (_jsx("div", { role: "alert", children: "Something went wrong." }));
18
+ /**
19
+ * Attaches the React component stack to the reported error (mirrors what
20
+ * faro-react does) so exception grouping keys off the component tree.
21
+ */
22
+ function errorWithComponentStack(error, errorInfo) {
23
+ const componentStack = errorInfo.componentStack;
24
+ if (!componentStack) {
25
+ return error;
26
+ }
27
+ const withStack = new Error(error.message);
28
+ withStack.name = `React ErrorBoundary ${error.name}`;
29
+ withStack.stack = componentStack;
30
+ return withStack;
31
+ }
32
+ /**
33
+ * Catches render errors in the subtree, reports them once through
34
+ * `captureException`, and renders a fallback. Sentry-compatible shape.
35
+ */
36
+ export class ApmErrorBoundary extends Component {
37
+ constructor(props) {
38
+ super(props);
39
+ this.state = { error: null };
40
+ this.resetErrorBoundary = this.resetErrorBoundary.bind(this);
41
+ }
42
+ static getDerivedStateFromError(error) {
43
+ // Claim the error before React 19's default `onCaughtError` logs it with
44
+ // `console.error` (which happens after this render-phase call and before
45
+ // `componentDidCatch`), so NaisConsoleInstrumentation skips it and this
46
+ // boundary stays the single reporter — with fingerprint and component
47
+ // stack attached. See nais/apm#36.
48
+ markErrorCaptured(error);
49
+ return { error };
50
+ }
51
+ componentDidCatch(error, errorInfo) {
52
+ const reported = errorWithComponentStack(error, errorInfo);
53
+ const { fingerprint } = this.props;
54
+ const resolvedFingerprint = typeof fingerprint === 'function' ? fingerprint(reported) : fingerprint;
55
+ // Single capture — routes through the SDK's fingerprint/context pipeline.
56
+ captureException(reported, {
57
+ context: this.props.context,
58
+ fingerprint: resolvedFingerprint,
59
+ });
60
+ this.props.onError?.(reported, errorInfo);
61
+ }
62
+ resetErrorBoundary() {
63
+ const { error } = this.state;
64
+ this.props.onReset?.(error);
65
+ this.setState({ error: null });
66
+ }
67
+ render() {
68
+ const { error } = this.state;
69
+ if (error === null) {
70
+ return this.props.children;
71
+ }
72
+ const { fallback } = this.props;
73
+ if (fallback === undefined) {
74
+ return defaultFallback;
75
+ }
76
+ const element = typeof fallback === 'function'
77
+ ? fallback(error, this.resetErrorBoundary)
78
+ : fallback;
79
+ return isValidElement(element) ? element : defaultFallback;
80
+ }
81
+ }
82
+ /**
83
+ * HOC that wraps a component in an {@link ApmErrorBoundary}. Sentry-compatible
84
+ * `withErrorBoundary` shape.
85
+ */
86
+ export function withApmErrorBoundary(WrappedComponent, errorBoundaryProps = {}) {
87
+ const Wrapper = (props) => (_jsx(ApmErrorBoundary, { ...errorBoundaryProps, children: _jsx(WrappedComponent, { ...props }) }));
88
+ const name = WrappedComponent.displayName ?? WrappedComponent.name ?? 'Component';
89
+ Wrapper.displayName = `withApmErrorBoundary(${name})`;
90
+ return Wrapper;
91
+ }
92
+ //# sourceMappingURL=ErrorBoundary.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ErrorBoundary.js","sourceRoot":"","sources":["../../src/react/ErrorBoundary.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAGlD,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAC7C,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAkCnD,MAAM,eAAe,GAAiB,CACpC,cAAK,IAAI,EAAC,OAAO,sCAA4B,CAC9C,CAAC;AAEF;;;GAGG;AACH,SAAS,uBAAuB,CAAC,KAAY,EAAE,SAAoB;IACjE,MAAM,cAAc,GAAG,SAAS,CAAC,cAAc,CAAC;IAChD,IAAI,CAAC,cAAc,EAAE,CAAC;QACpB,OAAO,KAAK,CAAC;IACf,CAAC;IACD,MAAM,SAAS,GAAG,IAAI,KAAK,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAC3C,SAAS,CAAC,IAAI,GAAG,uBAAuB,KAAK,CAAC,IAAI,EAAE,CAAC;IACrD,SAAS,CAAC,KAAK,GAAG,cAAc,CAAC;IACjC,OAAO,SAAS,CAAC;AACnB,CAAC;AAED;;;GAGG;AACH,MAAM,OAAO,gBAAiB,SAAQ,SAGrC;IAGC,YAAY,KAA4B;QACtC,KAAK,CAAC,KAAK,CAAC,CAAC;QAHN,UAAK,GAA0B,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;QAItD,IAAI,CAAC,kBAAkB,GAAG,IAAI,CAAC,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC/D,CAAC;IAED,MAAM,CAAC,wBAAwB,CAAC,KAAY;QAC1C,yEAAyE;QACzE,yEAAyE;QACzE,wEAAwE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AAK,UAAU;YAC5B,CAAC,CAAE,QAA2C,CAAC,KAAK,EAAE,IAAI,CAAC,kBAAkB,CAAC;YAC9E,CAAC,CAAC,QAAQ,CAAC;QACf,OAAO,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,CAAC;IAC7D,CAAC;CACF;AAED;;;GAGG;AACH,MAAM,UAAU,oBAAoB,CAClC,gBAAkC,EAClC,kBAAkB,GAA0B,EAAE;IAE9C,MAAM,OAAO,GAAG,CAAC,KAAQ,EAAgB,EAAE,CAAC,CAC1C,KAAC,gBAAgB,OAAK,kBAAkB,YACtC,KAAC,gBAAgB,OAAK,KAAK,GAAI,GACd,CACpB,CAAC;IACF,MAAM,IAAI,GACR,gBAAgB,CAAC,WAAW,IAAI,gBAAgB,CAAC,IAAI,IAAI,WAAW,CAAC;IACvE,OAAO,CAAC,WAAW,GAAG,wBAAwB,IAAI,GAAG,CAAC;IACtD,OAAO,OAAO,CAAC;AACjB,CAAC"}
@@ -0,0 +1,25 @@
1
+ /**
2
+ * `<NaisMetaTags />` — render the nais config meta tags from the pod's runtime
3
+ * environment (nais/grafana-apm-app#133 phase 2). Server-rendered so the
4
+ * browser-side `init()` resolves app/team/cluster/version/collector with zero
5
+ * hand-written tags.
6
+ *
7
+ * Usage:
8
+ * - Next.js Pages Router: inside `<Head>` in `_document.tsx`
9
+ * - Next.js App Router: inside the `<head>` element of the root layout
10
+ * (a server component — the env read happens on the server)
11
+ * - Any other React SSR: wherever the document head is rendered
12
+ */
13
+ import * as React from 'react';
14
+ import type { ConfigOptions, NaisGeneratedConfig } from '../config.js';
15
+ export interface NaisMetaTagsProps {
16
+ /** Explicit values that win over the generatedConfig payload and the pod env. */
17
+ overrides?: ConfigOptions;
18
+ /**
19
+ * The naiserator generatedConfig payload, when the server imports the
20
+ * mounted module (`await import(mountPath)`) and prefers it over raw env.
21
+ */
22
+ naisConfig?: NaisGeneratedConfig;
23
+ }
24
+ export declare function NaisMetaTags({ overrides, naisConfig }: NaisMetaTagsProps): React.ReactElement;
25
+ //# sourceMappingURL=NaisMetaTags.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NaisMetaTags.d.ts","sourceRoot":"","sources":["../../src/react/NaisMetaTags.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,KAAK,EAAE,aAAa,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAEvE,MAAM,WAAW,iBAAiB;IAChC,iFAAiF;IACjF,SAAS,CAAC,EAAE,aAAa,CAAC;IAC1B;;;OAGG;IACH,UAAU,CAAC,EAAE,mBAAmB,CAAC;CAClC;AAED,wBAAgB,YAAY,CAAC,EAAE,SAAS,EAAE,UAAU,EAAE,EAAE,iBAAiB,GAAG,KAAK,CAAC,YAAY,CAQ7F"}
@@ -0,0 +1,6 @@
1
+ import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime";
2
+ import { getNaisMetaTags } from '../metaTags.js';
3
+ export function NaisMetaTags({ overrides, naisConfig }) {
4
+ return (_jsx(_Fragment, { children: getNaisMetaTags(overrides, naisConfig).map(({ name, content }) => (_jsx("meta", { name: name, content: content }, name))) }));
5
+ }
6
+ //# sourceMappingURL=NaisMetaTags.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NaisMetaTags.js","sourceRoot":"","sources":["../../src/react/NaisMetaTags.tsx"],"names":[],"mappings":";AAeA,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAajD,MAAM,UAAU,YAAY,CAAC,EAAE,SAAS,EAAE,UAAU,EAAqB;IACvE,OAAO,CACL,4BACG,eAAe,CAAC,SAAS,EAAE,UAAU,CAAC,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CACjE,eAAiB,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,IAAlC,IAAI,CAAkC,CAClD,CAAC,GACD,CACJ,CAAC;AACJ,CAAC"}
@@ -0,0 +1,17 @@
1
+ /**
2
+ * `@nais/apm/react` — React entry point (nais/grafana-apm-app#79).
3
+ *
4
+ * Opt-in helpers for React apps: an error boundary that reports through the
5
+ * SDK's `captureException` pipeline, route-change tracking for React Router v6
6
+ * and the Next.js App Router, and a Next.js client-init helper. React and
7
+ * react-router are optional peer dependencies — importing this entry requires
8
+ * them (and `@grafana/faro-react` for the v6 route wiring).
9
+ */
10
+ export { ApmErrorBoundary, withApmErrorBoundary } from './ErrorBoundary.js';
11
+ export type { ApmErrorBoundaryProps, ApmErrorBoundaryFallbackRender, } from './ErrorBoundary.js';
12
+ export { ApmRoutes, enableApmReactRouterV6, useApmRouteTracking } from './routing.js';
13
+ export type { ReactRouterV6Dependencies } from './routing.js';
14
+ export { initNaisAPMClient } from './nextClient.js';
15
+ export { NaisMetaTags } from './NaisMetaTags.js';
16
+ export type { NaisMetaTagsProps } from './NaisMetaTags.js';
17
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/react/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC5E,YAAY,EACV,qBAAqB,EACrB,8BAA8B,GAC/B,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAAE,SAAS,EAAE,sBAAsB,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AACtF,YAAY,EAAE,yBAAyB,EAAE,MAAM,cAAc,CAAC;AAE9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAEpD,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,YAAY,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC"}
@@ -0,0 +1,14 @@
1
+ /**
2
+ * `@nais/apm/react` — React entry point (nais/grafana-apm-app#79).
3
+ *
4
+ * Opt-in helpers for React apps: an error boundary that reports through the
5
+ * SDK's `captureException` pipeline, route-change tracking for React Router v6
6
+ * and the Next.js App Router, and a Next.js client-init helper. React and
7
+ * react-router are optional peer dependencies — importing this entry requires
8
+ * them (and `@grafana/faro-react` for the v6 route wiring).
9
+ */
10
+ export { ApmErrorBoundary, withApmErrorBoundary } from './ErrorBoundary.js';
11
+ export { ApmRoutes, enableApmReactRouterV6, useApmRouteTracking } from './routing.js';
12
+ export { initNaisAPMClient } from './nextClient.js';
13
+ export { NaisMetaTags } from './NaisMetaTags.js';
14
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/react/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAM5E,OAAO,EAAE,SAAS,EAAE,sBAAsB,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAGtF,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAEpD,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC"}
@@ -0,0 +1,25 @@
1
+ /**
2
+ * Next.js client initialization helper for @nais/apm (nais/grafana-apm-app#79).
3
+ *
4
+ * `initNaisAPMClient` is the documented entry for Next 15+
5
+ * `instrumentation-client.ts` and the Pages Router `_app.tsx` pattern. It:
6
+ * - no-ops on the server (`typeof window === 'undefined'`), so it is safe to
7
+ * import into modules that also run in React Server Components / during SSR;
8
+ * - is idempotent: `init()` already self-guards against double
9
+ * initialization, so React StrictMode's double invoke or repeated imports
10
+ * return the existing Faro instance instead of re-initializing.
11
+ */
12
+ import type { InitOptions } from '../index.js';
13
+ import type { Faro } from '@grafana/faro-web-sdk';
14
+ /**
15
+ * Initialize @nais/apm from a Next.js client entry. Returns the Faro instance
16
+ * in the browser, or `undefined` when called on the server (a no-op).
17
+ *
18
+ * ```ts
19
+ * // instrumentation-client.ts (Next 15+)
20
+ * import { initNaisAPMClient } from '@nais/apm/react';
21
+ * initNaisAPMClient({ namespace: 'my-team' });
22
+ * ```
23
+ */
24
+ export declare function initNaisAPMClient(options?: InitOptions): Faro | undefined;
25
+ //# sourceMappingURL=nextClient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nextClient.d.ts","sourceRoot":"","sources":["../../src/react/nextClient.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;;;GASG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,GAAE,WAAgB,GAAG,IAAI,GAAG,SAAS,CAK7E"}
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Next.js client initialization helper for @nais/apm (nais/grafana-apm-app#79).
3
+ *
4
+ * `initNaisAPMClient` is the documented entry for Next 15+
5
+ * `instrumentation-client.ts` and the Pages Router `_app.tsx` pattern. It:
6
+ * - no-ops on the server (`typeof window === 'undefined'`), so it is safe to
7
+ * import into modules that also run in React Server Components / during SSR;
8
+ * - is idempotent: `init()` already self-guards against double
9
+ * initialization, so React StrictMode's double invoke or repeated imports
10
+ * return the existing Faro instance instead of re-initializing.
11
+ */
12
+ import { init } from '../index.js';
13
+ /**
14
+ * Initialize @nais/apm from a Next.js client entry. Returns the Faro instance
15
+ * in the browser, or `undefined` when called on the server (a no-op).
16
+ *
17
+ * ```ts
18
+ * // instrumentation-client.ts (Next 15+)
19
+ * import { initNaisAPMClient } from '@nais/apm/react';
20
+ * initNaisAPMClient({ namespace: 'my-team' });
21
+ * ```
22
+ */
23
+ export function initNaisAPMClient(options = {}) {
24
+ if (typeof window === 'undefined') {
25
+ return undefined;
26
+ }
27
+ return init(options);
28
+ }
29
+ //# sourceMappingURL=nextClient.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nextClient.js","sourceRoot":"","sources":["../../src/react/nextClient.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAInC;;;;;;;;;GASG;AACH,MAAM,UAAU,iBAAiB,CAAC,OAAO,GAAgB,EAAE;IACzD,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;QAClC,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,OAAO,IAAI,CAAC,OAAO,CAAC,CAAC;AACvB,CAAC"}
@@ -0,0 +1,56 @@
1
+ /**
2
+ * Route-change tracking for @nais/apm (nais/grafana-apm-app#79).
3
+ *
4
+ * Two supported routers:
5
+ * - React Router v6 (web): faro-react's `FaroRoutes`, re-exported as
6
+ * `ApmRoutes`, wired via {@link enableApmReactRouterV6} which injects the
7
+ * app's own react-router dependencies. We do NOT import react-router
8
+ * ourselves — it stays an optional peer, avoiding version drift.
9
+ * - Next.js App Router: {@link useApmRouteTracking}, our own small hook (no
10
+ * faro-react App Router integration exists). Pushes a Faro route-change
11
+ * event per pathname change.
12
+ *
13
+ * v5/v7 and the data-router variants are out of scope for 0.2.0 (follow-ups).
14
+ */
15
+ import { FaroRoutes } from '@grafana/faro-react';
16
+ import type { ReactRouterV6Dependencies } from '@grafana/faro-react';
17
+ /** Drop-in for react-router's `<Routes>` that reports route changes. */
18
+ export { FaroRoutes as ApmRoutes };
19
+ export type { ReactRouterV6Dependencies } from '@grafana/faro-react';
20
+ /**
21
+ * Enable React Router v6 route-change tracking. Call once after `init()`,
22
+ * passing your app's own react-router-dom exports:
23
+ *
24
+ * ```ts
25
+ * import { createRoutesFromChildren, matchRoutes, Routes, useLocation, useNavigationType } from 'react-router-dom';
26
+ * enableApmReactRouterV6({ createRoutesFromChildren, matchRoutes, Routes, useLocation, useNavigationType });
27
+ * ```
28
+ *
29
+ * Then render `<ApmRoutes>` where you would render `<Routes>`. Late-adds
30
+ * faro-react's `ReactIntegration` (OpenTelemetry-free) wired for v6.
31
+ */
32
+ export declare function enableApmReactRouterV6(dependencies: ReactRouterV6Dependencies): void;
33
+ /**
34
+ * Track route changes in a Next.js App Router app. There is no faro-react
35
+ * integration for the App Router, so this is our own hook: it pushes a Faro
36
+ * route-change event whenever the pathname (or search) changes.
37
+ *
38
+ * Call it in a client component with Next's navigation hooks:
39
+ *
40
+ * ```tsx
41
+ * 'use client';
42
+ * import { usePathname, useSearchParams } from 'next/navigation';
43
+ * import { useApmRouteTracking } from '@nais/apm/react';
44
+ *
45
+ * export function ApmRouteTracker() {
46
+ * useApmRouteTracking(usePathname(), useSearchParams());
47
+ * return null;
48
+ * }
49
+ * ```
50
+ *
51
+ * Passing the values in (rather than importing `next/navigation` here) keeps
52
+ * Next out of this package's dependency tree and makes the hook usable with any
53
+ * router that can supply a pathname.
54
+ */
55
+ export declare function useApmRouteTracking(pathname: string | null | undefined, searchParams?: URLSearchParams | string | null): void;
56
+ //# sourceMappingURL=routing.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"routing.d.ts","sourceRoot":"","sources":["../../src/react/routing.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAGH,OAAO,EACL,UAAU,EAGX,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAKrE,wEAAwE;AACxE,OAAO,EAAE,UAAU,IAAI,SAAS,EAAE,CAAC;AACnC,YAAY,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAErE;;;;;;;;;;;GAWG;AACH,wBAAgB,sBAAsB,CAAC,YAAY,EAAE,yBAAyB,GAAG,IAAI,CAUpF;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EACnC,YAAY,CAAC,EAAE,eAAe,GAAG,MAAM,GAAG,IAAI,GAC7C,IAAI,CA2BN"}
@@ -0,0 +1,89 @@
1
+ /**
2
+ * Route-change tracking for @nais/apm (nais/grafana-apm-app#79).
3
+ *
4
+ * Two supported routers:
5
+ * - React Router v6 (web): faro-react's `FaroRoutes`, re-exported as
6
+ * `ApmRoutes`, wired via {@link enableApmReactRouterV6} which injects the
7
+ * app's own react-router dependencies. We do NOT import react-router
8
+ * ourselves — it stays an optional peer, avoiding version drift.
9
+ * - Next.js App Router: {@link useApmRouteTracking}, our own small hook (no
10
+ * faro-react App Router integration exists). Pushes a Faro route-change
11
+ * event per pathname change.
12
+ *
13
+ * v5/v7 and the data-router variants are out of scope for 0.2.0 (follow-ups).
14
+ */
15
+ import { useEffect, useRef } from 'react';
16
+ import { FaroRoutes, ReactIntegration, createReactRouterV6Options, } from '@grafana/faro-react';
17
+ import { EVENT_ROUTE_CHANGE } from '@grafana/faro-web-sdk';
18
+ import { getFaroInstance } from '../internal.js';
19
+ /** Drop-in for react-router's `<Routes>` that reports route changes. */
20
+ export { FaroRoutes as ApmRoutes };
21
+ /**
22
+ * Enable React Router v6 route-change tracking. Call once after `init()`,
23
+ * passing your app's own react-router-dom exports:
24
+ *
25
+ * ```ts
26
+ * import { createRoutesFromChildren, matchRoutes, Routes, useLocation, useNavigationType } from 'react-router-dom';
27
+ * enableApmReactRouterV6({ createRoutesFromChildren, matchRoutes, Routes, useLocation, useNavigationType });
28
+ * ```
29
+ *
30
+ * Then render `<ApmRoutes>` where you would render `<Routes>`. Late-adds
31
+ * faro-react's `ReactIntegration` (OpenTelemetry-free) wired for v6.
32
+ */
33
+ export function enableApmReactRouterV6(dependencies) {
34
+ const faro = getFaroInstance();
35
+ if (!faro) {
36
+ return;
37
+ }
38
+ faro.instrumentations.add(new ReactIntegration({
39
+ router: createReactRouterV6Options(dependencies),
40
+ }));
41
+ }
42
+ /**
43
+ * Track route changes in a Next.js App Router app. There is no faro-react
44
+ * integration for the App Router, so this is our own hook: it pushes a Faro
45
+ * route-change event whenever the pathname (or search) changes.
46
+ *
47
+ * Call it in a client component with Next's navigation hooks:
48
+ *
49
+ * ```tsx
50
+ * 'use client';
51
+ * import { usePathname, useSearchParams } from 'next/navigation';
52
+ * import { useApmRouteTracking } from '@nais/apm/react';
53
+ *
54
+ * export function ApmRouteTracker() {
55
+ * useApmRouteTracking(usePathname(), useSearchParams());
56
+ * return null;
57
+ * }
58
+ * ```
59
+ *
60
+ * Passing the values in (rather than importing `next/navigation` here) keeps
61
+ * Next out of this package's dependency tree and makes the hook usable with any
62
+ * router that can supply a pathname.
63
+ */
64
+ export function useApmRouteTracking(pathname, searchParams) {
65
+ const search = searchParams == null
66
+ ? ''
67
+ : typeof searchParams === 'string'
68
+ ? searchParams
69
+ : searchParams.toString();
70
+ const url = pathname == null ? null : search ? `${pathname}?${search}` : pathname;
71
+ const previousUrl = useRef(null);
72
+ useEffect(() => {
73
+ if (url == null || previousUrl.current === url) {
74
+ return;
75
+ }
76
+ const fromUrl = previousUrl.current;
77
+ previousUrl.current = url;
78
+ const faro = getFaroInstance();
79
+ if (!faro) {
80
+ return;
81
+ }
82
+ faro.api.pushEvent(EVENT_ROUTE_CHANGE, {
83
+ toRoute: pathname ?? url,
84
+ toUrl: url,
85
+ ...(fromUrl ? { fromUrl } : {}),
86
+ });
87
+ }, [url, pathname]);
88
+ }
89
+ //# sourceMappingURL=routing.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"routing.js","sourceRoot":"","sources":["../../src/react/routing.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAC1C,OAAO,EACL,UAAU,EACV,gBAAgB,EAChB,0BAA0B,GAC3B,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAE3D,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAEjD,wEAAwE;AACxE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rC,OAAO,EAAE,QAAQ,IAAI,GAAG;YACxB,KAAK,EAAE,GAAG;YACV,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SAChC,CAAC,CAAC;IACL,CAAC,EAAE,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC,CAAC;AACtB,CAAC"}
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Wire-contract constants for the session-replay / snapshot pipeline
3
+ * (nais/grafana-apm-app#58, #67). This module is dependency-free on purpose:
4
+ * it is imported by the eagerly-loaded scrubber as well as the lazily-loaded
5
+ * replay machinery, and must never pull rrweb or fflate into the main bundle.
6
+ */
7
+ /**
8
+ * Faro event name for one replay chunk. The Nais APM plugin reader is built
9
+ * against this exact name — do not change without versioning the format.
10
+ */
11
+ export declare const REPLAY_CHUNK_EVENT_NAME = "faro.session_recording.chunk";
12
+ /** Encoding identifier carried in every chunk (`enc` attr); versions the wire format. */
13
+ export declare const REPLAY_ENCODING = "gzip+b64";
14
+ /**
15
+ * Hard cap on the `data` attr (base64 chars) per chunk. Keeps the resulting
16
+ * logfmt line safely under Loki's 256KB default `max_line_size` after Alloy's
17
+ * `event_data_*` flattening.
18
+ */
19
+ export declare const MAX_CHUNK_B64_CHARS = 96000;
20
+ /** Flush the event buffer when this much serialized JSON has accumulated. */
21
+ export declare const MAX_BUFFER_BYTES = 64000;
22
+ /** Flush the event buffer at least this often while events are pending. */
23
+ export declare const MAX_BUFFER_MS = 5000;
24
+ /** Capture mode carried in the `mode` attr of every chunk. */
25
+ export type ReplayMode = 'snapshot' | 'recording';
26
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/replay/constants.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH;;;GAGG;AACH,eAAO,MAAM,uBAAuB,iCAAiC,CAAC;AAEtE,yFAAyF;AACzF,eAAO,MAAM,eAAe,aAAa,CAAC;AAE1C;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,QAAS,CAAC;AAE1C,6EAA6E;AAC7E,eAAO,MAAM,gBAAgB,QAAS,CAAC;AAEvC,2EAA2E;AAC3E,eAAO,MAAM,aAAa,OAAQ,CAAC;AAEnC,8DAA8D;AAC9D,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,WAAW,CAAC"}
@@ -0,0 +1,24 @@
1
+ /**
2
+ * Wire-contract constants for the session-replay / snapshot pipeline
3
+ * (nais/grafana-apm-app#58, #67). This module is dependency-free on purpose:
4
+ * it is imported by the eagerly-loaded scrubber as well as the lazily-loaded
5
+ * replay machinery, and must never pull rrweb or fflate into the main bundle.
6
+ */
7
+ /**
8
+ * Faro event name for one replay chunk. The Nais APM plugin reader is built
9
+ * against this exact name — do not change without versioning the format.
10
+ */
11
+ export const REPLAY_CHUNK_EVENT_NAME = 'faro.session_recording.chunk';
12
+ /** Encoding identifier carried in every chunk (`enc` attr); versions the wire format. */
13
+ export const REPLAY_ENCODING = 'gzip+b64';
14
+ /**
15
+ * Hard cap on the `data` attr (base64 chars) per chunk. Keeps the resulting
16
+ * logfmt line safely under Loki's 256KB default `max_line_size` after Alloy's
17
+ * `event_data_*` flattening.
18
+ */
19
+ export const MAX_CHUNK_B64_CHARS = 96000;
20
+ /** Flush the event buffer when this much serialized JSON has accumulated. */
21
+ export const MAX_BUFFER_BYTES = 64000;
22
+ /** Flush the event buffer at least this often while events are pending. */
23
+ export const MAX_BUFFER_MS = 5000;
24
+ //# sourceMappingURL=constants.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/replay/constants.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH;;;GAGG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAAG,8BAA8B,CAAC;AAEtE,yFAAyF;AACzF,MAAM,CAAC,MAAM,eAAe,GAAG,UAAU,CAAC;AAE1C;;;;GAIG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,KAAM,CAAC;AAE1C,6EAA6E;AAC7E,MAAM,CAAC,MAAM,gBAAgB,GAAG,KAAM,CAAC;AAEvC,2EAA2E;AAC3E,MAAM,CAAC,MAAM,aAAa,GAAG,IAAK,CAAC"}
@@ -0,0 +1,74 @@
1
+ /**
2
+ * Events tier — the safe-default session-replay privacy tier
3
+ * (nais/grafana-apm-app#82).
4
+ *
5
+ * Derives a lightweight INTERACTION TIMELINE from DOM events and ships it as
6
+ * ordinary Faro events (`kind=event`, the A2 approach) — there is deliberately
7
+ * NO rrweb import on this path, so no rrweb ever lands in the safe-path bundle,
8
+ * and NO FullSnapshot / DOM node tree is ever produced. Structurally there is
9
+ * nothing to leak beyond URLs, which are run through `scrubUrl` first.
10
+ *
11
+ * Each event carries ONLY:
12
+ * - the target element's tag name and ARIA `role` (never id/class/text),
13
+ * - click coordinates (rounded viewport px),
14
+ * - a timestamp.
15
+ *
16
+ * It NEVER captures text content, input/form values, element ids, or a node
17
+ * tree. The one negative guarantee the events tier makes is the absence of the
18
+ * DOM.
19
+ *
20
+ * Trigger semantics mirror `recording.ts`:
21
+ * - `mode: 'on-error'` (default): the timeline is buffered in a bounded
22
+ * in-memory ring; nothing is sent until the first captured error, at which
23
+ * point the buffer is flushed and the collector switches to streaming.
24
+ * - `mode: 'always'`: every event is pushed as it happens.
25
+ */
26
+ /** Faro event names for the events-tier timeline. The plugin reader keys off these. */
27
+ export declare const EVENTS_NAVIGATION = "faro.session_events.navigation";
28
+ export declare const EVENTS_CLICK = "faro.session_events.click";
29
+ export declare const EVENTS_RAGE_CLICK = "faro.session_events.rage_click";
30
+ export declare const EVENTS_SCROLL = "faro.session_events.scroll";
31
+ export declare const EVENTS_ERROR = "faro.session_events.error";
32
+ /** Sink for one timeline event; in production this wraps `faro.api.pushEvent`. */
33
+ export type PushEvent = (name: string, attributes: Record<string, string>) => void;
34
+ /**
35
+ * Deterministic per-session sampling: the same session id always lands on the
36
+ * same side of the rate. Mirrors `recording.ts` so a session is either fully
37
+ * captured or not at all. (Kept local to avoid pulling the rrweb-adjacent
38
+ * recording module onto the events path.)
39
+ */
40
+ export declare function isSessionSampled(sessionId: string | undefined, sampleRate: number): boolean;
41
+ export interface EventsHandle {
42
+ /**
43
+ * Notify the collector that an error was captured. In `on-error` mode the
44
+ * first call flushes the buffered timeline, marks the error position, and
45
+ * switches to streaming; later calls only push an error marker.
46
+ */
47
+ notifyError(): void;
48
+ /** Stop collecting and remove all listeners / history patches. */
49
+ stop(): void;
50
+ /** True once events are streaming (always-mode, or after the first error). */
51
+ readonly isStreaming: boolean;
52
+ }
53
+ export interface StartEventsOptions {
54
+ mode: 'on-error' | 'always';
55
+ /** Fraction of sessions captured, 0..1. Default 1. */
56
+ sampleRate?: number;
57
+ push: PushEvent;
58
+ /** Faro session id, used for deterministic sampling. */
59
+ sessionId?: string;
60
+ /** @internal test seam: clock. */
61
+ now?: () => number;
62
+ }
63
+ /**
64
+ * Attach an events-tier error breadcrumb to the timeline WITHOUT any DOM node
65
+ * tree: a text-free marker carrying the current (scrubbed) URL and viewport.
66
+ * Used by `screenshotOnError` when the resolved tier is not `dom`.
67
+ */
68
+ export declare function pushErrorBreadcrumb(push: PushEvent): void;
69
+ /**
70
+ * Start the events-tier collector. Returns `undefined` when running outside a
71
+ * browser or the session is sampled out; never throws.
72
+ */
73
+ export declare function startEventsCollection(options: StartEventsOptions): EventsHandle | undefined;
74
+ //# sourceMappingURL=events.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../src/replay/events.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAMH,uFAAuF;AACvF,eAAO,MAAM,iBAAiB,mCAAmC,CAAC;AAClE,eAAO,MAAM,YAAY,8BAA8B,CAAC;AACxD,eAAO,MAAM,iBAAiB,mCAAmC,CAAC;AAClE,eAAO,MAAM,aAAa,+BAA+B,CAAC;AAC1D,eAA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