@starko-one/sdk 0.0.0-stage → 0.1.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +248 -0
- package/LICENSE +17 -0
- package/NOTICE +58 -0
- package/README.md +81 -2
- package/dist/api-BAFm4Lxj.d.ts +558 -0
- package/dist/api-DNrctwJu.d.cts +558 -0
- package/dist/browser/index.cjs +168 -0
- package/dist/browser/index.d.cts +131 -0
- package/dist/browser/index.d.ts +131 -0
- package/dist/browser/index.js +7 -0
- package/dist/build/rollup.cjs +22 -0
- package/dist/build/rollup.d.cts +34 -0
- package/dist/build/rollup.d.ts +34 -0
- package/dist/build/rollup.js +3 -0
- package/dist/build/vite.cjs +51 -0
- package/dist/build/vite.d.cts +23 -0
- package/dist/build/vite.d.ts +23 -0
- package/dist/build/vite.js +46 -0
- package/dist/build/webpack.cjs +18 -0
- package/dist/build/webpack.d.cts +39 -0
- package/dist/build/webpack.d.ts +39 -0
- package/dist/build/webpack.js +3 -0
- package/dist/chunk-2PM4FRM5.cjs +431 -0
- package/dist/chunk-335HNCOJ.js +249 -0
- package/dist/chunk-3AW5B2WW.js +115 -0
- package/dist/chunk-3R5TQAWD.js +216 -0
- package/dist/chunk-6H5MOPTQ.cjs +1230 -0
- package/dist/chunk-7TKNT3QJ.cjs +2487 -0
- package/dist/chunk-A4WLNFMU.cjs +220 -0
- package/dist/chunk-ALYFFOPR.cjs +134 -0
- package/dist/chunk-BVVFVRMO.js +1113 -0
- package/dist/chunk-CIHNKN62.cjs +15 -0
- package/dist/chunk-CMGCH6HD.js +1212 -0
- package/dist/chunk-D6QAPQ7L.cjs +56 -0
- package/dist/chunk-DUO5V6WZ.js +213 -0
- package/dist/chunk-EC2WZ6PG.js +90 -0
- package/dist/chunk-EFURLFJT.cjs +187 -0
- package/dist/chunk-EROUORMY.js +53 -0
- package/dist/chunk-LXBXFOAP.cjs +96 -0
- package/dist/chunk-MF6SA6DB.js +563 -0
- package/dist/chunk-N5R6ORIB.js +413 -0
- package/dist/chunk-N6R6BWHK.cjs +142 -0
- package/dist/chunk-QAGGN2T7.cjs +225 -0
- package/dist/chunk-QV4HRIDD.cjs +659 -0
- package/dist/chunk-TKNDYQB3.cjs +583 -0
- package/dist/chunk-UI5YC4TH.js +131 -0
- package/dist/chunk-VEHZYLK6.cjs +1151 -0
- package/dist/chunk-VNCWOGTI.js +12 -0
- package/dist/chunk-VWNIOGE6.js +180 -0
- package/dist/chunk-WDKRKGYF.js +608 -0
- package/dist/chunk-XOZIXBUK.js +2462 -0
- package/dist/chunk-ZS3K3SDR.cjs +258 -0
- package/dist/cli/index.cjs +2780 -0
- package/dist/common-DLFAqL2d.d.cts +36 -0
- package/dist/common-DbSXkaw6.d.ts +36 -0
- package/dist/dedupe-Bh5riD8Z.d.cts +13 -0
- package/dist/dedupe-DoYiSx-9.d.ts +13 -0
- package/dist/handler-BcnsnvhF.d.cts +82 -0
- package/dist/handler-qHzilC9T.d.ts +82 -0
- package/dist/index.cjs +309 -0
- package/dist/index.d.cts +187 -0
- package/dist/index.d.ts +187 -0
- package/dist/index.js +4 -0
- package/dist/next/client.cjs +113 -0
- package/dist/next/client.d.cts +26 -0
- package/dist/next/client.d.ts +26 -0
- package/dist/next/client.js +41 -0
- package/dist/next/config.cjs +277 -0
- package/dist/next/config.d.cts +193 -0
- package/dist/next/config.d.ts +193 -0
- package/dist/next/config.js +263 -0
- package/dist/next/index.cjs +148 -0
- package/dist/next/index.d.cts +32 -0
- package/dist/next/index.d.ts +32 -0
- package/dist/next/index.js +59 -0
- package/dist/node/index.cjs +257 -0
- package/dist/node/index.d.cts +145 -0
- package/dist/node/index.d.ts +145 -0
- package/dist/node/index.js +83 -0
- package/dist/options-BUhWuWJX.d.cts +79 -0
- package/dist/options-BUhWuWJX.d.ts +79 -0
- package/dist/react/index.cjs +107 -0
- package/dist/react/index.d.cts +84 -0
- package/dist/react/index.d.ts +84 -0
- package/dist/react/index.js +103 -0
- package/dist/scope-D1ouJm2h.d.cts +628 -0
- package/dist/scope-D1ouJm2h.d.ts +628 -0
- package/dist/server-edge-7624N3WF.cjs +51 -0
- package/dist/server-edge-BEEXWL7T.js +48 -0
- package/dist/server-node-ET4LIPEC.cjs +27 -0
- package/dist/server-node-TQUVMZUC.js +24 -0
- package/dist/session-C_WzbEN2.d.cts +4 -0
- package/dist/session-C_WzbEN2.d.ts +4 -0
- package/dist/session-propagation-Pr0Zb9Zn.d.cts +30 -0
- package/dist/session-propagation-RM5py1bp.d.ts +30 -0
- package/dist/starko.min.js +6 -0
- package/docs/browser.md +386 -0
- package/docs/configuration.md +310 -0
- package/docs/nextjs.md +488 -0
- package/docs/node.md +427 -0
- package/docs/other-backends.md +232 -0
- package/docs/privacy.md +112 -0
- package/docs/react.md +187 -0
- package/docs/source-maps.md +482 -0
- package/docs/troubleshooting.md +263 -0
- package/docs/widget.md +84 -0
- package/docs/wire-format.md +547 -0
- package/package.json +191 -4
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkTKNDYQB3_cjs = require('../chunk-TKNDYQB3.cjs');
|
|
4
|
+
var chunkALYFFOPR_cjs = require('../chunk-ALYFFOPR.cjs');
|
|
5
|
+
var chunk6H5MOPTQ_cjs = require('../chunk-6H5MOPTQ.cjs');
|
|
6
|
+
var chunkCIHNKN62_cjs = require('../chunk-CIHNKN62.cjs');
|
|
7
|
+
require('../chunk-ZS3K3SDR.cjs');
|
|
8
|
+
var chunkQV4HRIDD_cjs = require('../chunk-QV4HRIDD.cjs');
|
|
9
|
+
require('../chunk-N6R6BWHK.cjs');
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
Object.defineProperty(exports, "BRIDGE_EVENT", {
|
|
14
|
+
enumerable: true,
|
|
15
|
+
get: function () { return chunkTKNDYQB3_cjs.BRIDGE_EVENT; }
|
|
16
|
+
});
|
|
17
|
+
Object.defineProperty(exports, "BRIDGE_GLOBAL", {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
get: function () { return chunkTKNDYQB3_cjs.BRIDGE_GLOBAL; }
|
|
20
|
+
});
|
|
21
|
+
Object.defineProperty(exports, "SESSION_STORAGE_KEY", {
|
|
22
|
+
enumerable: true,
|
|
23
|
+
get: function () { return chunkTKNDYQB3_cjs.SESSION_STORAGE_KEY; }
|
|
24
|
+
});
|
|
25
|
+
Object.defineProperty(exports, "breadcrumbsIntegration", {
|
|
26
|
+
enumerable: true,
|
|
27
|
+
get: function () { return chunkTKNDYQB3_cjs.breadcrumbsIntegration; }
|
|
28
|
+
});
|
|
29
|
+
Object.defineProperty(exports, "browserIsInApp", {
|
|
30
|
+
enumerable: true,
|
|
31
|
+
get: function () { return chunkTKNDYQB3_cjs.browserIsInApp; }
|
|
32
|
+
});
|
|
33
|
+
Object.defineProperty(exports, "consoleErrorCaptureIntegration", {
|
|
34
|
+
enumerable: true,
|
|
35
|
+
get: function () { return chunkTKNDYQB3_cjs.consoleErrorCaptureIntegration; }
|
|
36
|
+
});
|
|
37
|
+
Object.defineProperty(exports, "describeElement", {
|
|
38
|
+
enumerable: true,
|
|
39
|
+
get: function () { return chunkTKNDYQB3_cjs.describeElement; }
|
|
40
|
+
});
|
|
41
|
+
Object.defineProperty(exports, "flushOnHideIntegration", {
|
|
42
|
+
enumerable: true,
|
|
43
|
+
get: function () { return chunkTKNDYQB3_cjs.flushOnHideIntegration; }
|
|
44
|
+
});
|
|
45
|
+
Object.defineProperty(exports, "getBridge", {
|
|
46
|
+
enumerable: true,
|
|
47
|
+
get: function () { return chunkTKNDYQB3_cjs.getBridge; }
|
|
48
|
+
});
|
|
49
|
+
Object.defineProperty(exports, "getDefaultIntegrations", {
|
|
50
|
+
enumerable: true,
|
|
51
|
+
get: function () { return chunkTKNDYQB3_cjs.getDefaultIntegrations; }
|
|
52
|
+
});
|
|
53
|
+
Object.defineProperty(exports, "getOwnSessionId", {
|
|
54
|
+
enumerable: true,
|
|
55
|
+
get: function () { return chunkTKNDYQB3_cjs.getOwnSessionId; }
|
|
56
|
+
});
|
|
57
|
+
Object.defineProperty(exports, "globalHandlersIntegration", {
|
|
58
|
+
enumerable: true,
|
|
59
|
+
get: function () { return chunkTKNDYQB3_cjs.globalHandlersIntegration; }
|
|
60
|
+
});
|
|
61
|
+
Object.defineProperty(exports, "httpContextIntegration", {
|
|
62
|
+
enumerable: true,
|
|
63
|
+
get: function () { return chunkTKNDYQB3_cjs.httpContextIntegration; }
|
|
64
|
+
});
|
|
65
|
+
Object.defineProperty(exports, "inboundDropReason", {
|
|
66
|
+
enumerable: true,
|
|
67
|
+
get: function () { return chunkTKNDYQB3_cjs.inboundDropReason; }
|
|
68
|
+
});
|
|
69
|
+
Object.defineProperty(exports, "inboundFiltersIntegration", {
|
|
70
|
+
enumerable: true,
|
|
71
|
+
get: function () { return chunkTKNDYQB3_cjs.inboundFiltersIntegration; }
|
|
72
|
+
});
|
|
73
|
+
Object.defineProperty(exports, "init", {
|
|
74
|
+
enumerable: true,
|
|
75
|
+
get: function () { return chunkTKNDYQB3_cjs.init; }
|
|
76
|
+
});
|
|
77
|
+
Object.defineProperty(exports, "registerOwnScript", {
|
|
78
|
+
enumerable: true,
|
|
79
|
+
get: function () { return chunkTKNDYQB3_cjs.registerOwnScript; }
|
|
80
|
+
});
|
|
81
|
+
Object.defineProperty(exports, "sessionPropagationIntegration", {
|
|
82
|
+
enumerable: true,
|
|
83
|
+
get: function () { return chunkTKNDYQB3_cjs.sessionPropagationIntegration; }
|
|
84
|
+
});
|
|
85
|
+
Object.defineProperty(exports, "widgetBridgeIntegration", {
|
|
86
|
+
enumerable: true,
|
|
87
|
+
get: function () { return chunkTKNDYQB3_cjs.widgetBridgeIntegration; }
|
|
88
|
+
});
|
|
89
|
+
Object.defineProperty(exports, "makeFetchTransport", {
|
|
90
|
+
enumerable: true,
|
|
91
|
+
get: function () { return chunkALYFFOPR_cjs.makeFetchTransport; }
|
|
92
|
+
});
|
|
93
|
+
Object.defineProperty(exports, "dedupeIntegration", {
|
|
94
|
+
enumerable: true,
|
|
95
|
+
get: function () { return chunk6H5MOPTQ_cjs.dedupeIntegration; }
|
|
96
|
+
});
|
|
97
|
+
Object.defineProperty(exports, "SESSION_HEADER", {
|
|
98
|
+
enumerable: true,
|
|
99
|
+
get: function () { return chunkCIHNKN62_cjs.SESSION_HEADER; }
|
|
100
|
+
});
|
|
101
|
+
Object.defineProperty(exports, "SDK_VERSION", {
|
|
102
|
+
enumerable: true,
|
|
103
|
+
get: function () { return chunkQV4HRIDD_cjs.SDK_VERSION; }
|
|
104
|
+
});
|
|
105
|
+
Object.defineProperty(exports, "addBreadcrumb", {
|
|
106
|
+
enumerable: true,
|
|
107
|
+
get: function () { return chunkQV4HRIDD_cjs.addBreadcrumb; }
|
|
108
|
+
});
|
|
109
|
+
Object.defineProperty(exports, "captureException", {
|
|
110
|
+
enumerable: true,
|
|
111
|
+
get: function () { return chunkQV4HRIDD_cjs.captureException; }
|
|
112
|
+
});
|
|
113
|
+
Object.defineProperty(exports, "captureMessage", {
|
|
114
|
+
enumerable: true,
|
|
115
|
+
get: function () { return chunkQV4HRIDD_cjs.captureMessage; }
|
|
116
|
+
});
|
|
117
|
+
Object.defineProperty(exports, "close", {
|
|
118
|
+
enumerable: true,
|
|
119
|
+
get: function () { return chunkQV4HRIDD_cjs.close; }
|
|
120
|
+
});
|
|
121
|
+
Object.defineProperty(exports, "flush", {
|
|
122
|
+
enumerable: true,
|
|
123
|
+
get: function () { return chunkQV4HRIDD_cjs.flush; }
|
|
124
|
+
});
|
|
125
|
+
Object.defineProperty(exports, "getClient", {
|
|
126
|
+
enumerable: true,
|
|
127
|
+
get: function () { return chunkQV4HRIDD_cjs.getClient; }
|
|
128
|
+
});
|
|
129
|
+
Object.defineProperty(exports, "getCurrentScope", {
|
|
130
|
+
enumerable: true,
|
|
131
|
+
get: function () { return chunkQV4HRIDD_cjs.getCurrentScope; }
|
|
132
|
+
});
|
|
133
|
+
Object.defineProperty(exports, "getGlobalScope", {
|
|
134
|
+
enumerable: true,
|
|
135
|
+
get: function () { return chunkQV4HRIDD_cjs.getGlobalScope; }
|
|
136
|
+
});
|
|
137
|
+
Object.defineProperty(exports, "identify", {
|
|
138
|
+
enumerable: true,
|
|
139
|
+
get: function () { return chunkQV4HRIDD_cjs.identify; }
|
|
140
|
+
});
|
|
141
|
+
Object.defineProperty(exports, "setContext", {
|
|
142
|
+
enumerable: true,
|
|
143
|
+
get: function () { return chunkQV4HRIDD_cjs.setContext; }
|
|
144
|
+
});
|
|
145
|
+
Object.defineProperty(exports, "setExtra", {
|
|
146
|
+
enumerable: true,
|
|
147
|
+
get: function () { return chunkQV4HRIDD_cjs.setExtra; }
|
|
148
|
+
});
|
|
149
|
+
Object.defineProperty(exports, "setExtras", {
|
|
150
|
+
enumerable: true,
|
|
151
|
+
get: function () { return chunkQV4HRIDD_cjs.setExtras; }
|
|
152
|
+
});
|
|
153
|
+
Object.defineProperty(exports, "setTag", {
|
|
154
|
+
enumerable: true,
|
|
155
|
+
get: function () { return chunkQV4HRIDD_cjs.setTag; }
|
|
156
|
+
});
|
|
157
|
+
Object.defineProperty(exports, "setTags", {
|
|
158
|
+
enumerable: true,
|
|
159
|
+
get: function () { return chunkQV4HRIDD_cjs.setTags; }
|
|
160
|
+
});
|
|
161
|
+
Object.defineProperty(exports, "setUser", {
|
|
162
|
+
enumerable: true,
|
|
163
|
+
get: function () { return chunkQV4HRIDD_cjs.setUser; }
|
|
164
|
+
});
|
|
165
|
+
Object.defineProperty(exports, "withScope", {
|
|
166
|
+
enumerable: true,
|
|
167
|
+
get: function () { return chunkQV4HRIDD_cjs.withScope; }
|
|
168
|
+
});
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
export { B as BrowserOptions, b as browserIsInApp, f as flushOnHideIntegration, g as getDefaultIntegrations, i as init, s as sessionPropagationIntegration } from '../session-propagation-Pr0Zb9Zn.cjs';
|
|
2
|
+
import { I as Integration, T as TransportOptions, a as Transport } from '../api-DNrctwJu.cjs';
|
|
3
|
+
export { C as Client, E as EventHint, O as Options, S as SDK_VERSION, b as TransportResult, c as addBreadcrumb, d as captureException, e as captureMessage, f as close, g as flush, h as getClient, i as getCurrentScope, j as getGlobalScope, k as identify, s as setContext, l as setExtra, m as setExtras, n as setTag, o as setTags, p as setUser, w as withScope } from '../api-DNrctwJu.cjs';
|
|
4
|
+
import { W as WireEvent } from '../scope-D1ouJm2h.cjs';
|
|
5
|
+
export { B as Breadcrumb, L as Level, S as Scope, a as WireUser } from '../scope-D1ouJm2h.cjs';
|
|
6
|
+
export { S as SESSION_HEADER } from '../session-C_WzbEN2.cjs';
|
|
7
|
+
export { d as dedupeIntegration } from '../dedupe-Bh5riD8Z.cjs';
|
|
8
|
+
|
|
9
|
+
interface GlobalHandlersOptions {
|
|
10
|
+
onerror?: boolean;
|
|
11
|
+
onunhandledrejection?: boolean;
|
|
12
|
+
}
|
|
13
|
+
declare function globalHandlersIntegration(opts?: GlobalHandlersOptions): Integration & {
|
|
14
|
+
captures: boolean;
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
interface BreadcrumbsOptions {
|
|
18
|
+
console?: boolean;
|
|
19
|
+
dom?: boolean;
|
|
20
|
+
fetch?: boolean;
|
|
21
|
+
xhr?: boolean;
|
|
22
|
+
history?: boolean;
|
|
23
|
+
}
|
|
24
|
+
/** `div#app > form.login > button[type="submit"]`, at most 5 levels and 120 characters. */
|
|
25
|
+
declare function describeElement(el: unknown): string;
|
|
26
|
+
declare function breadcrumbsIntegration(opts?: BreadcrumbsOptions): Integration;
|
|
27
|
+
|
|
28
|
+
declare function consoleErrorCaptureIntegration(opts?: {
|
|
29
|
+
whenWidget?: boolean;
|
|
30
|
+
}): Integration;
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Drops noise before it leaves the page. The rules are the ones the Starko
|
|
34
|
+
* server applies to widget-reported errors (starko-v2
|
|
35
|
+
* lib/widget-errors/fingerprint.ts) and the widget's own pre-filter
|
|
36
|
+
* (starko-widget-v2 src/lib/error-reporting.ts), applied to the first
|
|
37
|
+
* exception of a built event:
|
|
38
|
+
*
|
|
39
|
+
* - empty message (`""`, `undefined`, `null`, `[object Object]`, `error`)
|
|
40
|
+
* AND no stack;
|
|
41
|
+
* - cross-origin `Script error.` without a stack;
|
|
42
|
+
* - a browser extension in the top 3 frames;
|
|
43
|
+
* - `ResizeObserver loop …`;
|
|
44
|
+
* - aborted requests (`AbortError`, "The operation was aborted", …);
|
|
45
|
+
* - plain network failures (`Failed to fetch`, `Load failed`, …), and
|
|
46
|
+
* `NetworkError` without a stack;
|
|
47
|
+
* - errors raised entirely inside Starko scripts (the widget, the recorder,
|
|
48
|
+
* or this SDK's script-tag bundle): EVERY frame with a real file is a
|
|
49
|
+
* Starko script. A host bug that only passes through a Starko frame (a
|
|
50
|
+
* second `xhr.send()` throws inside the SDK's wrapper) has host frames
|
|
51
|
+
* too and is reported.
|
|
52
|
+
*
|
|
53
|
+
* Difference from the server rule: an empty message WITH a stack is kept
|
|
54
|
+
* (`throw new Error()` still points at a bug).
|
|
55
|
+
*/
|
|
56
|
+
|
|
57
|
+
declare function registerOwnScript(src: string | null | undefined): void;
|
|
58
|
+
/** Why the event is noise, or null when it should be reported. */
|
|
59
|
+
declare function inboundDropReason(event: WireEvent): string | null;
|
|
60
|
+
declare function inboundFiltersIntegration(): Integration;
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Adds the page to every event: `request.url` (`location.href`) and
|
|
64
|
+
* `request.referrer`. When the event is built the URL privacy defaults
|
|
65
|
+
* apply (core/url.ts): the `#fragment` is dropped and the values of
|
|
66
|
+
* sensitive query parameters (`SENSITIVE_QUERY_PARAMS`) become
|
|
67
|
+
* `[redacted]`; every other query parameter IS sent. Remove more in
|
|
68
|
+
* `beforeSend` if your URLs carry personal data under other names.
|
|
69
|
+
*/
|
|
70
|
+
|
|
71
|
+
declare function httpContextIntegration(): Integration;
|
|
72
|
+
|
|
73
|
+
declare const BRIDGE_GLOBAL = "__STARKO_BRIDGE__";
|
|
74
|
+
declare const BRIDGE_EVENT = "starko:bridge";
|
|
75
|
+
interface StarkoBridge {
|
|
76
|
+
sdk?: {
|
|
77
|
+
version: string;
|
|
78
|
+
readonly capturesErrors?: boolean;
|
|
79
|
+
getSessionId(): string;
|
|
80
|
+
captureException(error: unknown, hint?: object): string;
|
|
81
|
+
};
|
|
82
|
+
widget?: {
|
|
83
|
+
getReplaySessionId(): string | null;
|
|
84
|
+
getClientToken(): string | null;
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
declare function getBridge(): StarkoBridge | undefined;
|
|
88
|
+
declare function widgetBridgeIntegration(): Integration;
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* Fetch transport. `Content-Type: text/plain` so the cross-origin POST is a
|
|
92
|
+
* "simple" request (no CORS preflight); the server accepts any content type.
|
|
93
|
+
*
|
|
94
|
+
* The `fetch` it uses is the one the page had when the SDK loaded (without
|
|
95
|
+
* the SDK's own wrapper, if another copy installed one), bound to the global
|
|
96
|
+
* object: code that patches `fetch` later (to add the host's own
|
|
97
|
+
* `Authorization` header, say) never sees Starko's requests, and the SDK's
|
|
98
|
+
* own breadcrumb and session-header hooks never see them either. A page that
|
|
99
|
+
* patched `fetch` BEFORE the SDK loaded keeps its patch: the SDK does not dig
|
|
100
|
+
* a pristine `fetch` out of a temporary iframe (DOM writes the session
|
|
101
|
+
* recorder and the host's observers would see, functions of a detached realm
|
|
102
|
+
* that some browsers refuse to run); a header such a patch adds makes the
|
|
103
|
+
* browser send a CORS preflight, which the ingest API refuses for anything
|
|
104
|
+
* but its own headers, so the credential never reaches Starko.
|
|
105
|
+
*
|
|
106
|
+
* Every request (the remote config too) has a deadline, `timeoutMs`
|
|
107
|
+
* (default `REQUEST_TIMEOUT_MS`): a proxy or a captive portal that never
|
|
108
|
+
* answers is aborted and reported as a network failure (status 0).
|
|
109
|
+
*
|
|
110
|
+
* Redirects are never followed (`redirect: "manual"`): following one would
|
|
111
|
+
* turn the POST into a GET and lose the event while the SDK counted it as
|
|
112
|
+
* sent. A browser hides a manual redirect (an "opaqueredirect" response,
|
|
113
|
+
* status 0, no `Location`); it is reported as a 3xx, which the queue logs
|
|
114
|
+
* once and drops.
|
|
115
|
+
*
|
|
116
|
+
* Keepalive: browsers cap the bodies of in-flight `keepalive` requests at
|
|
117
|
+
* 64 KiB in total. The bytes in flight are counted across sends; a request
|
|
118
|
+
* that would go over `KEEPALIVE_BUDGET` is still sent, without `keepalive`
|
|
119
|
+
* (it may be cut off if the page is really unloading).
|
|
120
|
+
*/
|
|
121
|
+
|
|
122
|
+
interface FetchTransportOptions extends TransportOptions {
|
|
123
|
+
/** Defaults to the `fetch` the page had when the SDK loaded. */
|
|
124
|
+
fetchImpl?: typeof fetch;
|
|
125
|
+
}
|
|
126
|
+
declare function makeFetchTransport(options: FetchTransportOptions): Transport;
|
|
127
|
+
|
|
128
|
+
declare const SESSION_STORAGE_KEY = "starko:errors:session";
|
|
129
|
+
declare function getOwnSessionId(): string;
|
|
130
|
+
|
|
131
|
+
export { BRIDGE_EVENT, BRIDGE_GLOBAL, type BreadcrumbsOptions, type FetchTransportOptions, type GlobalHandlersOptions, Integration, SESSION_STORAGE_KEY, type StarkoBridge, Transport, TransportOptions, WireEvent, breadcrumbsIntegration, consoleErrorCaptureIntegration, describeElement, getBridge, getOwnSessionId, globalHandlersIntegration, httpContextIntegration, inboundDropReason, inboundFiltersIntegration, makeFetchTransport, registerOwnScript, widgetBridgeIntegration };
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
export { B as BrowserOptions, b as browserIsInApp, f as flushOnHideIntegration, g as getDefaultIntegrations, i as init, s as sessionPropagationIntegration } from '../session-propagation-RM5py1bp.js';
|
|
2
|
+
import { I as Integration, T as TransportOptions, a as Transport } from '../api-BAFm4Lxj.js';
|
|
3
|
+
export { C as Client, E as EventHint, O as Options, S as SDK_VERSION, b as TransportResult, c as addBreadcrumb, d as captureException, e as captureMessage, f as close, g as flush, h as getClient, i as getCurrentScope, j as getGlobalScope, k as identify, s as setContext, l as setExtra, m as setExtras, n as setTag, o as setTags, p as setUser, w as withScope } from '../api-BAFm4Lxj.js';
|
|
4
|
+
import { W as WireEvent } from '../scope-D1ouJm2h.js';
|
|
5
|
+
export { B as Breadcrumb, L as Level, S as Scope, a as WireUser } from '../scope-D1ouJm2h.js';
|
|
6
|
+
export { S as SESSION_HEADER } from '../session-C_WzbEN2.js';
|
|
7
|
+
export { d as dedupeIntegration } from '../dedupe-DoYiSx-9.js';
|
|
8
|
+
|
|
9
|
+
interface GlobalHandlersOptions {
|
|
10
|
+
onerror?: boolean;
|
|
11
|
+
onunhandledrejection?: boolean;
|
|
12
|
+
}
|
|
13
|
+
declare function globalHandlersIntegration(opts?: GlobalHandlersOptions): Integration & {
|
|
14
|
+
captures: boolean;
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
interface BreadcrumbsOptions {
|
|
18
|
+
console?: boolean;
|
|
19
|
+
dom?: boolean;
|
|
20
|
+
fetch?: boolean;
|
|
21
|
+
xhr?: boolean;
|
|
22
|
+
history?: boolean;
|
|
23
|
+
}
|
|
24
|
+
/** `div#app > form.login > button[type="submit"]`, at most 5 levels and 120 characters. */
|
|
25
|
+
declare function describeElement(el: unknown): string;
|
|
26
|
+
declare function breadcrumbsIntegration(opts?: BreadcrumbsOptions): Integration;
|
|
27
|
+
|
|
28
|
+
declare function consoleErrorCaptureIntegration(opts?: {
|
|
29
|
+
whenWidget?: boolean;
|
|
30
|
+
}): Integration;
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Drops noise before it leaves the page. The rules are the ones the Starko
|
|
34
|
+
* server applies to widget-reported errors (starko-v2
|
|
35
|
+
* lib/widget-errors/fingerprint.ts) and the widget's own pre-filter
|
|
36
|
+
* (starko-widget-v2 src/lib/error-reporting.ts), applied to the first
|
|
37
|
+
* exception of a built event:
|
|
38
|
+
*
|
|
39
|
+
* - empty message (`""`, `undefined`, `null`, `[object Object]`, `error`)
|
|
40
|
+
* AND no stack;
|
|
41
|
+
* - cross-origin `Script error.` without a stack;
|
|
42
|
+
* - a browser extension in the top 3 frames;
|
|
43
|
+
* - `ResizeObserver loop …`;
|
|
44
|
+
* - aborted requests (`AbortError`, "The operation was aborted", …);
|
|
45
|
+
* - plain network failures (`Failed to fetch`, `Load failed`, …), and
|
|
46
|
+
* `NetworkError` without a stack;
|
|
47
|
+
* - errors raised entirely inside Starko scripts (the widget, the recorder,
|
|
48
|
+
* or this SDK's script-tag bundle): EVERY frame with a real file is a
|
|
49
|
+
* Starko script. A host bug that only passes through a Starko frame (a
|
|
50
|
+
* second `xhr.send()` throws inside the SDK's wrapper) has host frames
|
|
51
|
+
* too and is reported.
|
|
52
|
+
*
|
|
53
|
+
* Difference from the server rule: an empty message WITH a stack is kept
|
|
54
|
+
* (`throw new Error()` still points at a bug).
|
|
55
|
+
*/
|
|
56
|
+
|
|
57
|
+
declare function registerOwnScript(src: string | null | undefined): void;
|
|
58
|
+
/** Why the event is noise, or null when it should be reported. */
|
|
59
|
+
declare function inboundDropReason(event: WireEvent): string | null;
|
|
60
|
+
declare function inboundFiltersIntegration(): Integration;
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Adds the page to every event: `request.url` (`location.href`) and
|
|
64
|
+
* `request.referrer`. When the event is built the URL privacy defaults
|
|
65
|
+
* apply (core/url.ts): the `#fragment` is dropped and the values of
|
|
66
|
+
* sensitive query parameters (`SENSITIVE_QUERY_PARAMS`) become
|
|
67
|
+
* `[redacted]`; every other query parameter IS sent. Remove more in
|
|
68
|
+
* `beforeSend` if your URLs carry personal data under other names.
|
|
69
|
+
*/
|
|
70
|
+
|
|
71
|
+
declare function httpContextIntegration(): Integration;
|
|
72
|
+
|
|
73
|
+
declare const BRIDGE_GLOBAL = "__STARKO_BRIDGE__";
|
|
74
|
+
declare const BRIDGE_EVENT = "starko:bridge";
|
|
75
|
+
interface StarkoBridge {
|
|
76
|
+
sdk?: {
|
|
77
|
+
version: string;
|
|
78
|
+
readonly capturesErrors?: boolean;
|
|
79
|
+
getSessionId(): string;
|
|
80
|
+
captureException(error: unknown, hint?: object): string;
|
|
81
|
+
};
|
|
82
|
+
widget?: {
|
|
83
|
+
getReplaySessionId(): string | null;
|
|
84
|
+
getClientToken(): string | null;
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
declare function getBridge(): StarkoBridge | undefined;
|
|
88
|
+
declare function widgetBridgeIntegration(): Integration;
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* Fetch transport. `Content-Type: text/plain` so the cross-origin POST is a
|
|
92
|
+
* "simple" request (no CORS preflight); the server accepts any content type.
|
|
93
|
+
*
|
|
94
|
+
* The `fetch` it uses is the one the page had when the SDK loaded (without
|
|
95
|
+
* the SDK's own wrapper, if another copy installed one), bound to the global
|
|
96
|
+
* object: code that patches `fetch` later (to add the host's own
|
|
97
|
+
* `Authorization` header, say) never sees Starko's requests, and the SDK's
|
|
98
|
+
* own breadcrumb and session-header hooks never see them either. A page that
|
|
99
|
+
* patched `fetch` BEFORE the SDK loaded keeps its patch: the SDK does not dig
|
|
100
|
+
* a pristine `fetch` out of a temporary iframe (DOM writes the session
|
|
101
|
+
* recorder and the host's observers would see, functions of a detached realm
|
|
102
|
+
* that some browsers refuse to run); a header such a patch adds makes the
|
|
103
|
+
* browser send a CORS preflight, which the ingest API refuses for anything
|
|
104
|
+
* but its own headers, so the credential never reaches Starko.
|
|
105
|
+
*
|
|
106
|
+
* Every request (the remote config too) has a deadline, `timeoutMs`
|
|
107
|
+
* (default `REQUEST_TIMEOUT_MS`): a proxy or a captive portal that never
|
|
108
|
+
* answers is aborted and reported as a network failure (status 0).
|
|
109
|
+
*
|
|
110
|
+
* Redirects are never followed (`redirect: "manual"`): following one would
|
|
111
|
+
* turn the POST into a GET and lose the event while the SDK counted it as
|
|
112
|
+
* sent. A browser hides a manual redirect (an "opaqueredirect" response,
|
|
113
|
+
* status 0, no `Location`); it is reported as a 3xx, which the queue logs
|
|
114
|
+
* once and drops.
|
|
115
|
+
*
|
|
116
|
+
* Keepalive: browsers cap the bodies of in-flight `keepalive` requests at
|
|
117
|
+
* 64 KiB in total. The bytes in flight are counted across sends; a request
|
|
118
|
+
* that would go over `KEEPALIVE_BUDGET` is still sent, without `keepalive`
|
|
119
|
+
* (it may be cut off if the page is really unloading).
|
|
120
|
+
*/
|
|
121
|
+
|
|
122
|
+
interface FetchTransportOptions extends TransportOptions {
|
|
123
|
+
/** Defaults to the `fetch` the page had when the SDK loaded. */
|
|
124
|
+
fetchImpl?: typeof fetch;
|
|
125
|
+
}
|
|
126
|
+
declare function makeFetchTransport(options: FetchTransportOptions): Transport;
|
|
127
|
+
|
|
128
|
+
declare const SESSION_STORAGE_KEY = "starko:errors:session";
|
|
129
|
+
declare function getOwnSessionId(): string;
|
|
130
|
+
|
|
131
|
+
export { BRIDGE_EVENT, BRIDGE_GLOBAL, type BreadcrumbsOptions, type FetchTransportOptions, type GlobalHandlersOptions, Integration, SESSION_STORAGE_KEY, type StarkoBridge, Transport, TransportOptions, WireEvent, breadcrumbsIntegration, consoleErrorCaptureIntegration, describeElement, getBridge, getOwnSessionId, globalHandlersIntegration, httpContextIntegration, inboundDropReason, inboundFiltersIntegration, makeFetchTransport, registerOwnScript, widgetBridgeIntegration };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { BRIDGE_EVENT, BRIDGE_GLOBAL, SESSION_STORAGE_KEY, breadcrumbsIntegration, browserIsInApp, consoleErrorCaptureIntegration, describeElement, flushOnHideIntegration, getBridge, getDefaultIntegrations, getOwnSessionId, globalHandlersIntegration, httpContextIntegration, inboundDropReason, inboundFiltersIntegration, init, registerOwnScript, sessionPropagationIntegration, widgetBridgeIntegration } from '../chunk-MF6SA6DB.js';
|
|
2
|
+
export { makeFetchTransport } from '../chunk-UI5YC4TH.js';
|
|
3
|
+
export { dedupeIntegration } from '../chunk-CMGCH6HD.js';
|
|
4
|
+
export { SESSION_HEADER } from '../chunk-VNCWOGTI.js';
|
|
5
|
+
import '../chunk-335HNCOJ.js';
|
|
6
|
+
export { SDK_VERSION, addBreadcrumb, captureException, captureMessage, close, flush, getClient, getCurrentScope, getGlobalScope, identify, setContext, setExtra, setExtras, setTag, setTags, setUser, withScope } from '../chunk-WDKRKGYF.js';
|
|
7
|
+
import '../chunk-3AW5B2WW.js';
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var chunkQAGGN2T7_cjs = require('../chunk-QAGGN2T7.cjs');
|
|
6
|
+
require('../chunk-7TKNT3QJ.cjs');
|
|
7
|
+
require('../chunk-N6R6BWHK.cjs');
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
Object.defineProperty(exports, "createStarkoRollupPlugin", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return chunkQAGGN2T7_cjs.createStarkoRollupPlugin; }
|
|
14
|
+
});
|
|
15
|
+
Object.defineProperty(exports, "default", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return chunkQAGGN2T7_cjs.rollup_default; }
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports, "starkoRollupPlugin", {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function () { return chunkQAGGN2T7_cjs.starkoRollupPlugin; }
|
|
22
|
+
});
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { Plugin } from 'rollup';
|
|
2
|
+
import { S as SourcemapOwner, a as StarkoBuildOptions } from '../options-BUhWuWJX.cjs';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Options of the Rollup plugin. `enabled` defaults to true except in watch
|
|
6
|
+
* mode or when `NODE_ENV` is `development`.
|
|
7
|
+
*/
|
|
8
|
+
type StarkoRollupPluginOptions = StarkoBuildOptions;
|
|
9
|
+
/** @internal How a wrapping plugin (Vite) decides whether the build is enabled and who asked for the maps. */
|
|
10
|
+
interface RollupPluginInternals {
|
|
11
|
+
name?: string;
|
|
12
|
+
isEnabled?: (context: {
|
|
13
|
+
meta: {
|
|
14
|
+
watchMode?: boolean;
|
|
15
|
+
};
|
|
16
|
+
}) => boolean;
|
|
17
|
+
/** Who made the output emit source maps (Vite switches them on in its config hook, before Rollup sees them). */
|
|
18
|
+
sourcemapOwner?: () => SourcemapOwner;
|
|
19
|
+
}
|
|
20
|
+
/** @internal Shared by the Rollup and Vite plugins. */
|
|
21
|
+
declare function createStarkoRollupPlugin(options?: StarkoRollupPluginOptions, internals?: RollupPluginInternals): Plugin;
|
|
22
|
+
/**
|
|
23
|
+
* Rollup plugin: gives every output chunk a debug id (snippet, trailing
|
|
24
|
+
* comment, `debugId` in its map) and uploads the maps to Starko just before
|
|
25
|
+
* the bundle is written. Without an API key it changes nothing.
|
|
26
|
+
*
|
|
27
|
+
* Source maps: when the output has none, the plugin switches them on
|
|
28
|
+
* (`hidden`) for the upload and removes them from the bundle afterwards,
|
|
29
|
+
* whatever the upload's outcome, so they are never written. Maps your output
|
|
30
|
+
* options ask for are kept unless `deleteSourcemapsAfterUpload: true`.
|
|
31
|
+
*/
|
|
32
|
+
declare function starkoRollupPlugin(options?: StarkoRollupPluginOptions): Plugin;
|
|
33
|
+
|
|
34
|
+
export { type RollupPluginInternals, StarkoBuildOptions, type StarkoRollupPluginOptions, createStarkoRollupPlugin, starkoRollupPlugin as default, starkoRollupPlugin };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { Plugin } from 'rollup';
|
|
2
|
+
import { S as SourcemapOwner, a as StarkoBuildOptions } from '../options-BUhWuWJX.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Options of the Rollup plugin. `enabled` defaults to true except in watch
|
|
6
|
+
* mode or when `NODE_ENV` is `development`.
|
|
7
|
+
*/
|
|
8
|
+
type StarkoRollupPluginOptions = StarkoBuildOptions;
|
|
9
|
+
/** @internal How a wrapping plugin (Vite) decides whether the build is enabled and who asked for the maps. */
|
|
10
|
+
interface RollupPluginInternals {
|
|
11
|
+
name?: string;
|
|
12
|
+
isEnabled?: (context: {
|
|
13
|
+
meta: {
|
|
14
|
+
watchMode?: boolean;
|
|
15
|
+
};
|
|
16
|
+
}) => boolean;
|
|
17
|
+
/** Who made the output emit source maps (Vite switches them on in its config hook, before Rollup sees them). */
|
|
18
|
+
sourcemapOwner?: () => SourcemapOwner;
|
|
19
|
+
}
|
|
20
|
+
/** @internal Shared by the Rollup and Vite plugins. */
|
|
21
|
+
declare function createStarkoRollupPlugin(options?: StarkoRollupPluginOptions, internals?: RollupPluginInternals): Plugin;
|
|
22
|
+
/**
|
|
23
|
+
* Rollup plugin: gives every output chunk a debug id (snippet, trailing
|
|
24
|
+
* comment, `debugId` in its map) and uploads the maps to Starko just before
|
|
25
|
+
* the bundle is written. Without an API key it changes nothing.
|
|
26
|
+
*
|
|
27
|
+
* Source maps: when the output has none, the plugin switches them on
|
|
28
|
+
* (`hidden`) for the upload and removes them from the bundle afterwards,
|
|
29
|
+
* whatever the upload's outcome, so they are never written. Maps your output
|
|
30
|
+
* options ask for are kept unless `deleteSourcemapsAfterUpload: true`.
|
|
31
|
+
*/
|
|
32
|
+
declare function starkoRollupPlugin(options?: StarkoRollupPluginOptions): Plugin;
|
|
33
|
+
|
|
34
|
+
export { type RollupPluginInternals, StarkoBuildOptions, type StarkoRollupPluginOptions, createStarkoRollupPlugin, starkoRollupPlugin as default, starkoRollupPlugin };
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var chunkQAGGN2T7_cjs = require('../chunk-QAGGN2T7.cjs');
|
|
6
|
+
var chunk7TKNT3QJ_cjs = require('../chunk-7TKNT3QJ.cjs');
|
|
7
|
+
require('../chunk-N6R6BWHK.cjs');
|
|
8
|
+
|
|
9
|
+
// src/build/vite.ts
|
|
10
|
+
function starkoVitePlugin(options = {}) {
|
|
11
|
+
const connection = chunk7TKNT3QJ_cjs.resolveConnection(options);
|
|
12
|
+
const logger = chunk7TKNT3QJ_cjs.createLogger({ silent: options.silent, secrets: [connection.apiKey] });
|
|
13
|
+
let enabled = false;
|
|
14
|
+
let owner = "user";
|
|
15
|
+
let warnedNoKey = false;
|
|
16
|
+
const wanted = (command, mode, watch) => options.enabled ?? (command === "build" && mode === "production" && !watch);
|
|
17
|
+
const base = chunkQAGGN2T7_cjs.createStarkoRollupPlugin(options, {
|
|
18
|
+
name: "starko-vite-plugin",
|
|
19
|
+
isEnabled: () => enabled,
|
|
20
|
+
sourcemapOwner: () => owner
|
|
21
|
+
});
|
|
22
|
+
return {
|
|
23
|
+
...base,
|
|
24
|
+
apply: "build",
|
|
25
|
+
enforce: "post",
|
|
26
|
+
config(userConfig, env) {
|
|
27
|
+
owner = "user";
|
|
28
|
+
if (!wanted(env.command, env.mode, userConfig.build?.watch) || !connection.apiKey) return;
|
|
29
|
+
if (!userConfig.build?.sourcemap) {
|
|
30
|
+
owner = "starko";
|
|
31
|
+
return { build: { sourcemap: "hidden" } };
|
|
32
|
+
}
|
|
33
|
+
return;
|
|
34
|
+
},
|
|
35
|
+
configResolved(config) {
|
|
36
|
+
enabled = wanted(config.command, config.mode, config.build.watch);
|
|
37
|
+
if (enabled && !connection.apiKey) {
|
|
38
|
+
if (!warnedNoKey) logger.warn(chunk7TKNT3QJ_cjs.NO_API_KEY_MESSAGE);
|
|
39
|
+
warnedNoKey = true;
|
|
40
|
+
enabled = false;
|
|
41
|
+
}
|
|
42
|
+
if (enabled && config.build.sourcemap === "inline") {
|
|
43
|
+
logger.warn("build.sourcemap is 'inline': inline source maps are not uploaded; use true or 'hidden'");
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
var vite_default = starkoVitePlugin;
|
|
49
|
+
|
|
50
|
+
exports.default = vite_default;
|
|
51
|
+
exports.starkoVitePlugin = starkoVitePlugin;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Plugin } from 'vite';
|
|
2
|
+
import { a as StarkoBuildOptions } from '../options-BUhWuWJX.cjs';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Options of the Vite plugin. `enabled` defaults to `vite build` in
|
|
6
|
+
* production mode, not in watch mode (`vite build --watch`).
|
|
7
|
+
*/
|
|
8
|
+
type StarkoVitePluginOptions = StarkoBuildOptions;
|
|
9
|
+
/**
|
|
10
|
+
* Vite plugin: the Rollup plugin, applied to builds only, after Vite's own
|
|
11
|
+
* plugins (minification included). Without an API key it changes nothing.
|
|
12
|
+
*
|
|
13
|
+
* Source maps: when `build.sourcemap` is not set (or false), the plugin makes
|
|
14
|
+
* Vite emit `hidden` maps for the upload and removes them from the output
|
|
15
|
+
* before it is written, whatever the upload's outcome, so they are never
|
|
16
|
+
* served or published (library mode included). Maps your config asks for
|
|
17
|
+
* (`build.sourcemap: true | 'hidden'`) are kept unless
|
|
18
|
+
* `deleteSourcemapsAfterUpload: true`. Under Vite's Rolldown pipeline the
|
|
19
|
+
* injection runs on the final code in generateBundle (see the Rollup plugin).
|
|
20
|
+
*/
|
|
21
|
+
declare function starkoVitePlugin(options?: StarkoVitePluginOptions): Plugin;
|
|
22
|
+
|
|
23
|
+
export { StarkoBuildOptions, type StarkoVitePluginOptions, starkoVitePlugin as default, starkoVitePlugin };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Plugin } from 'vite';
|
|
2
|
+
import { a as StarkoBuildOptions } from '../options-BUhWuWJX.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Options of the Vite plugin. `enabled` defaults to `vite build` in
|
|
6
|
+
* production mode, not in watch mode (`vite build --watch`).
|
|
7
|
+
*/
|
|
8
|
+
type StarkoVitePluginOptions = StarkoBuildOptions;
|
|
9
|
+
/**
|
|
10
|
+
* Vite plugin: the Rollup plugin, applied to builds only, after Vite's own
|
|
11
|
+
* plugins (minification included). Without an API key it changes nothing.
|
|
12
|
+
*
|
|
13
|
+
* Source maps: when `build.sourcemap` is not set (or false), the plugin makes
|
|
14
|
+
* Vite emit `hidden` maps for the upload and removes them from the output
|
|
15
|
+
* before it is written, whatever the upload's outcome, so they are never
|
|
16
|
+
* served or published (library mode included). Maps your config asks for
|
|
17
|
+
* (`build.sourcemap: true | 'hidden'`) are kept unless
|
|
18
|
+
* `deleteSourcemapsAfterUpload: true`. Under Vite's Rolldown pipeline the
|
|
19
|
+
* injection runs on the final code in generateBundle (see the Rollup plugin).
|
|
20
|
+
*/
|
|
21
|
+
declare function starkoVitePlugin(options?: StarkoVitePluginOptions): Plugin;
|
|
22
|
+
|
|
23
|
+
export { StarkoBuildOptions, type StarkoVitePluginOptions, starkoVitePlugin as default, starkoVitePlugin };
|