@datadog/vite-plugin 3.2.12-dev.1 → 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.
@@ -36,14 +36,24 @@ type types = {
36
36
  };
37
37
  declare const getPlugins: GetPlugins;
38
38
  type MinifiedPathPrefix = `http://${string}` | `https://${string}` | `/${string}`;
39
- type SourcemapsOptions = {
39
+ type SourcemapsUploadOptions = {
40
40
  bailOnError?: boolean;
41
41
  dryRun?: boolean;
42
42
  maxConcurrency?: number;
43
+ };
44
+ type DebugIdSourcemapsOptions = SourcemapsUploadOptions & {
45
+ debugId: true;
46
+ minifiedPathPrefix?: never;
47
+ releaseVersion?: never;
48
+ service?: never;
49
+ };
50
+ type ServiceVersionSourcemapsOptions = SourcemapsUploadOptions & {
51
+ debugId?: false;
43
52
  minifiedPathPrefix: MinifiedPathPrefix;
44
53
  releaseVersion?: string;
45
54
  service: string;
46
55
  };
56
+ type SourcemapsOptions = DebugIdSourcemapsOptions | ServiceVersionSourcemapsOptions;
47
57
  type ErrorTrackingOptions = {
48
58
  enable?: boolean;
49
59
  sourcemaps?: SourcemapsOptions;
@@ -63,6 +73,11 @@ declare const VALID_FUNCTION_KINDS: readonly [
63
73
  "classPrivateMethod"
64
74
  ];
65
75
  type FunctionKind = (typeof VALID_FUNCTION_KINDS)[number];
76
+ declare const VALID_DECORATOR_SYNTAXES: readonly [
77
+ "legacy",
78
+ "modern"
79
+ ];
80
+ type DecoratorSyntax = (typeof VALID_DECORATOR_SYNTAXES)[number];
66
81
  type LiveDebuggerOptions = {
67
82
  enable?: boolean;
68
83
  include?: (string | RegExp)[];
@@ -70,6 +85,7 @@ type LiveDebuggerOptions = {
70
85
  honorSkipComments?: boolean;
71
86
  functionTypes?: FunctionKind[];
72
87
  namedOnly?: boolean;
88
+ decorators?: DecoratorSyntax;
73
89
  };
74
90
  type LiveDebuggerOptionsWithDefaults = {
75
91
  version: string | undefined;
@@ -78,6 +94,7 @@ type LiveDebuggerOptionsWithDefaults = {
78
94
  honorSkipComments: boolean;
79
95
  functionTypes: FunctionKind[] | undefined;
80
96
  namedOnly: boolean;
97
+ decorators: DecoratorSyntax;
81
98
  };
82
99
  declare const CONFIG_KEY$2: "liveDebugger";
83
100
  declare const PLUGIN_NAME$2: PluginName;
@@ -5086,11 +5103,17 @@ interface PrivacyOptions {
5086
5103
  addToDictionaryFunctionName?: string;
5087
5104
  helperCodeExpression?: string;
5088
5105
  }
5089
- type SourceCodeContextOptions = {
5106
+ type DebugIdSourceCodeContextOptions = {
5107
+ debugId: true;
5090
5108
  service?: string;
5091
5109
  version?: string;
5092
- debugId?: boolean;
5093
5110
  };
5111
+ type ServiceVersionSourceCodeContextOptions = {
5112
+ debugId?: false;
5113
+ service: string;
5114
+ version?: string;
5115
+ };
5116
+ type SourceCodeContextOptions = DebugIdSourceCodeContextOptions | ServiceVersionSourceCodeContextOptions;
5094
5117
  type RumOptions = {
5095
5118
  enable?: boolean;
5096
5119
  sdk?: SDKOptions;
@@ -5362,6 +5385,21 @@ interface BaseOptions {
5362
5385
  enableGit?: boolean;
5363
5386
  logLevel?: LogLevel;
5364
5387
  }
5388
+ type SourcemapsUploadEnabledOptions = {
5389
+ upload: true;
5390
+ bailOnError?: boolean;
5391
+ dryRun?: boolean;
5392
+ maxConcurrency?: number;
5393
+ };
5394
+ type SourcemapsInjectionOnlyOptions = {
5395
+ upload?: false;
5396
+ bailOnError?: never;
5397
+ dryRun?: never;
5398
+ maxConcurrency?: never;
5399
+ };
5400
+ type SourcemapsOptions$1 = {
5401
+ debugId: true;
5402
+ } & (SourcemapsUploadEnabledOptions | SourcemapsInjectionOnlyOptions);
5365
5403
  interface Options extends BaseOptions {
5366
5404
  [CONFIG_KEY]?: AppsOptions;
5367
5405
  [CONFIG_KEY$1]?: ErrorTrackingOptions;
@@ -5369,6 +5407,7 @@ interface Options extends BaseOptions {
5369
5407
  [CONFIG_KEY$3]?: MetricsOptions;
5370
5408
  [CONFIG_KEY$4]?: OutputOptions;
5371
5409
  [rum.CONFIG_KEY]?: RumOptions;
5410
+ sourcemaps?: SourcemapsOptions$1;
5372
5411
  customPlugins?: GetCustomPlugins;
5373
5412
  }
5374
5413
  type OptionsWithDefaults = Assign<Assign<Options, Required<BaseOptions>>, {