@datadog/rspack-plugin 3.2.12 → 3.3.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/src/index.d.ts +61 -31
- package/dist/src/index.js +1 -1
- package/dist/src/index.js.map +1 -1
- package/dist/src/index.mjs +1 -1
- package/dist/src/index.mjs.map +1 -1
- package/package.json +3 -5
package/dist/src/index.d.ts
CHANGED
|
@@ -9,36 +9,24 @@ declare class TrackedFilesMatcher {
|
|
|
9
9
|
rawTrackedFilesList(): string[];
|
|
10
10
|
private getFilename;
|
|
11
11
|
}
|
|
12
|
-
type
|
|
13
|
-
|
|
12
|
+
type LongPollingOptions = {
|
|
13
|
+
/** Max long-poll attempts. `1` polls once and never retries. Default: `10`. */
|
|
14
|
+
maxRetries?: number;
|
|
15
|
+
/** Randomize retry delays so concurrent pollers don't sync up. Default: `true`. */
|
|
16
|
+
jitter?: boolean;
|
|
17
|
+
/** Grow the delay between retries exponentially. Default: `true`. */
|
|
18
|
+
exponentialBackoff?: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Deadline for one attempt, in ms. Must stay above the server's ~30s window,
|
|
21
|
+
* otherwise healthy polls get aborted. Default: `40000`.
|
|
22
|
+
*/
|
|
23
|
+
timeoutMs?: number;
|
|
24
|
+
};
|
|
14
25
|
type AppsOptions = {
|
|
15
26
|
enable?: boolean;
|
|
16
27
|
include?: string[];
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
name?: string;
|
|
20
|
-
/** Human-readable description of the app. */
|
|
21
|
-
description?: string;
|
|
22
|
-
/** When true, the app appears in the Datadog self-service catalog. */
|
|
23
|
-
selfService?: boolean;
|
|
24
|
-
/** Deployment and identity settings for the app. */
|
|
25
|
-
permissions?: {
|
|
26
|
-
/**
|
|
27
|
-
* Controls whether publishing the app requires a second approver.
|
|
28
|
-
* - `direct_publish`: any user with publish rights can deploy immediately.
|
|
29
|
-
* - `approval_required`: a second user must approve before the app goes live.
|
|
30
|
-
*/
|
|
31
|
-
protectionLevel?: AppsProtectionLevel;
|
|
32
|
-
/**
|
|
33
|
-
* UUID of the service account the app's backend functions run as.
|
|
34
|
-
* When omitted the app runs as the uploading user.
|
|
35
|
-
* Only service accounts are accepted; arbitrary user UUIDs are rejected by the API.
|
|
36
|
-
*/
|
|
37
|
-
runAs?: string;
|
|
38
|
-
};
|
|
39
|
-
authOverrides?: {
|
|
40
|
-
method?: AuthMethod;
|
|
41
|
-
};
|
|
28
|
+
/** Controls how the dev server retries the Datadog long-poll execution endpoint. */
|
|
29
|
+
longPolling?: LongPollingOptions;
|
|
42
30
|
};
|
|
43
31
|
declare const CONFIG_KEY: "apps";
|
|
44
32
|
declare const PLUGIN_NAME: PluginName;
|
|
@@ -47,14 +35,24 @@ type types = {
|
|
|
47
35
|
};
|
|
48
36
|
declare const getPlugins: GetPlugins;
|
|
49
37
|
type MinifiedPathPrefix = `http://${string}` | `https://${string}` | `/${string}`;
|
|
50
|
-
type
|
|
38
|
+
type SourcemapsUploadOptions = {
|
|
51
39
|
bailOnError?: boolean;
|
|
52
40
|
dryRun?: boolean;
|
|
53
41
|
maxConcurrency?: number;
|
|
42
|
+
};
|
|
43
|
+
type DebugIdSourcemapsOptions = SourcemapsUploadOptions & {
|
|
44
|
+
debugId: true;
|
|
45
|
+
minifiedPathPrefix?: never;
|
|
46
|
+
releaseVersion?: never;
|
|
47
|
+
service?: never;
|
|
48
|
+
};
|
|
49
|
+
type ServiceVersionSourcemapsOptions = SourcemapsUploadOptions & {
|
|
50
|
+
debugId?: false;
|
|
54
51
|
minifiedPathPrefix: MinifiedPathPrefix;
|
|
55
52
|
releaseVersion?: string;
|
|
56
53
|
service: string;
|
|
57
54
|
};
|
|
55
|
+
type SourcemapsOptions = DebugIdSourcemapsOptions | ServiceVersionSourcemapsOptions;
|
|
58
56
|
type ErrorTrackingOptions = {
|
|
59
57
|
enable?: boolean;
|
|
60
58
|
sourcemaps?: SourcemapsOptions;
|
|
@@ -74,6 +72,11 @@ declare const VALID_FUNCTION_KINDS: readonly [
|
|
|
74
72
|
"classPrivateMethod"
|
|
75
73
|
];
|
|
76
74
|
type FunctionKind = (typeof VALID_FUNCTION_KINDS)[number];
|
|
75
|
+
declare const VALID_DECORATOR_SYNTAXES: readonly [
|
|
76
|
+
"legacy",
|
|
77
|
+
"modern"
|
|
78
|
+
];
|
|
79
|
+
type DecoratorSyntax = (typeof VALID_DECORATOR_SYNTAXES)[number];
|
|
77
80
|
type LiveDebuggerOptions = {
|
|
78
81
|
enable?: boolean;
|
|
79
82
|
include?: (string | RegExp)[];
|
|
@@ -81,6 +84,7 @@ type LiveDebuggerOptions = {
|
|
|
81
84
|
honorSkipComments?: boolean;
|
|
82
85
|
functionTypes?: FunctionKind[];
|
|
83
86
|
namedOnly?: boolean;
|
|
87
|
+
decorators?: DecoratorSyntax;
|
|
84
88
|
};
|
|
85
89
|
type LiveDebuggerOptionsWithDefaults = {
|
|
86
90
|
version: string | undefined;
|
|
@@ -89,6 +93,7 @@ type LiveDebuggerOptionsWithDefaults = {
|
|
|
89
93
|
honorSkipComments: boolean;
|
|
90
94
|
functionTypes: FunctionKind[] | undefined;
|
|
91
95
|
namedOnly: boolean;
|
|
96
|
+
decorators: DecoratorSyntax;
|
|
92
97
|
};
|
|
93
98
|
declare const CONFIG_KEY$2: "liveDebugger";
|
|
94
99
|
declare const PLUGIN_NAME$2: PluginName;
|
|
@@ -5097,11 +5102,17 @@ interface PrivacyOptions {
|
|
|
5097
5102
|
addToDictionaryFunctionName?: string;
|
|
5098
5103
|
helperCodeExpression?: string;
|
|
5099
5104
|
}
|
|
5100
|
-
type
|
|
5105
|
+
type DebugIdSourceCodeContextOptions = {
|
|
5106
|
+
debugId: true;
|
|
5101
5107
|
service?: string;
|
|
5102
5108
|
version?: string;
|
|
5103
|
-
debugId?: boolean;
|
|
5104
5109
|
};
|
|
5110
|
+
type ServiceVersionSourceCodeContextOptions = {
|
|
5111
|
+
debugId?: false;
|
|
5112
|
+
service: string;
|
|
5113
|
+
version?: string;
|
|
5114
|
+
};
|
|
5115
|
+
type SourceCodeContextOptions = DebugIdSourceCodeContextOptions | ServiceVersionSourceCodeContextOptions;
|
|
5105
5116
|
type RumOptions = {
|
|
5106
5117
|
enable?: boolean;
|
|
5107
5118
|
sdk?: SDKOptions;
|
|
@@ -5293,6 +5304,8 @@ type Env = (typeof ALL_ENVS)[number];
|
|
|
5293
5304
|
type TriggerHook<R> = <K extends keyof CustomHooks>(name: K, ...args: Parameters<NonNullable<CustomHooks[K]>>) => R;
|
|
5294
5305
|
type GlobalContext = {
|
|
5295
5306
|
addMetric: (metric: Metric) => void;
|
|
5307
|
+
artifactsPending: boolean;
|
|
5308
|
+
artifactsReady: Promise<void>;
|
|
5296
5309
|
asyncHook: TriggerHook<Promise<void[]>>;
|
|
5297
5310
|
auth: AuthOptionsWithDefaults;
|
|
5298
5311
|
build: BuildReport;
|
|
@@ -5303,6 +5316,8 @@ type GlobalContext = {
|
|
|
5303
5316
|
git?: RepositoryData;
|
|
5304
5317
|
hook: TriggerHook<void>;
|
|
5305
5318
|
inject: (item: ToInjectItem) => void;
|
|
5319
|
+
markArtifactsPending: () => void;
|
|
5320
|
+
markArtifactsReady: (error?: unknown) => void;
|
|
5306
5321
|
pluginNames: string[];
|
|
5307
5322
|
plugins: (PluginOptions | CustomPluginOptions)[];
|
|
5308
5323
|
queue: (promise: Promise<any>) => void;
|
|
@@ -5362,7 +5377,6 @@ type AuthOptions = {
|
|
|
5362
5377
|
};
|
|
5363
5378
|
type AuthOptionsWithDefaults = Omit<AuthOptions, "site"> & {
|
|
5364
5379
|
site: Site$1;
|
|
5365
|
-
siteSubdomain?: string;
|
|
5366
5380
|
};
|
|
5367
5381
|
interface BaseOptions {
|
|
5368
5382
|
auth?: AuthOptions;
|
|
@@ -5370,6 +5384,21 @@ interface BaseOptions {
|
|
|
5370
5384
|
enableGit?: boolean;
|
|
5371
5385
|
logLevel?: LogLevel;
|
|
5372
5386
|
}
|
|
5387
|
+
type SourcemapsUploadEnabledOptions = {
|
|
5388
|
+
upload: true;
|
|
5389
|
+
bailOnError?: boolean;
|
|
5390
|
+
dryRun?: boolean;
|
|
5391
|
+
maxConcurrency?: number;
|
|
5392
|
+
};
|
|
5393
|
+
type SourcemapsInjectionOnlyOptions = {
|
|
5394
|
+
upload?: false;
|
|
5395
|
+
bailOnError?: never;
|
|
5396
|
+
dryRun?: never;
|
|
5397
|
+
maxConcurrency?: never;
|
|
5398
|
+
};
|
|
5399
|
+
type SourcemapsOptions$1 = {
|
|
5400
|
+
debugId: true;
|
|
5401
|
+
} & (SourcemapsUploadEnabledOptions | SourcemapsInjectionOnlyOptions);
|
|
5373
5402
|
interface Options extends BaseOptions {
|
|
5374
5403
|
[CONFIG_KEY]?: AppsOptions;
|
|
5375
5404
|
[CONFIG_KEY$1]?: ErrorTrackingOptions;
|
|
@@ -5377,6 +5406,7 @@ interface Options extends BaseOptions {
|
|
|
5377
5406
|
[CONFIG_KEY$3]?: MetricsOptions;
|
|
5378
5407
|
[CONFIG_KEY$4]?: OutputOptions;
|
|
5379
5408
|
[rum.CONFIG_KEY]?: RumOptions;
|
|
5409
|
+
sourcemaps?: SourcemapsOptions$1;
|
|
5380
5410
|
customPlugins?: GetCustomPlugins;
|
|
5381
5411
|
}
|
|
5382
5412
|
type OptionsWithDefaults = Assign<Assign<Options, Required<BaseOptions>>, {
|