@rolldown/browser 1.0.0-beta.9-commit.273d50e → 1.0.0-beta.9-commit.b174110
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/cli.cjs +10 -10
- package/dist/cli.mjs +55 -44
- package/dist/config.cjs +2 -2
- package/dist/config.d.cts +1 -1
- package/dist/config.d.mts +1 -1
- package/dist/config.mjs +4 -4
- package/dist/experimental-index.browser.mjs +1 -1
- package/dist/experimental-index.cjs +1 -1
- package/dist/experimental-index.d.cts +1 -1
- package/dist/experimental-index.d.mts +1 -1
- package/dist/experimental-index.mjs +4 -3
- package/dist/filter-index.d.cts +1 -1
- package/dist/filter-index.d.mts +1 -1
- package/dist/filter-index.mjs +2 -1
- package/dist/index.browser.mjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.mjs +3 -3
- package/dist/parallel-plugin-worker.cjs +1 -1
- package/dist/parallel-plugin-worker.mjs +3 -3
- package/dist/parallel-plugin.d.cts +1 -1
- package/dist/parallel-plugin.d.mts +1 -1
- package/dist/parse-ast-index.mjs +1 -1
- package/dist/rolldown-binding.wasm32-wasi.wasm +0 -0
- package/dist/shared/{define-config.d-gqmzo185.d.cts → define-config.d-D4lKXE9V.d.cts} +19 -19
- package/dist/shared/{define-config.d-GTTTro2-.d.mts → define-config.d-Dm9iNdt9.d.mts} +19 -19
- package/dist/shared/dist-CAn6dxW6.mjs +153 -0
- package/dist/shared/{load-config-gIb0d07e.mjs → load-config-CV_7wWhH.mjs} +1 -1
- package/dist/shared/{load-config-xy-ScCWb.cjs → load-config-DegJq4hI.cjs} +1 -1
- package/dist/shared/{parse-ast-index-Bx70S80g.mjs → parse-ast-index-vu376yZ1.mjs} +13 -3
- package/dist/shared/{src-j8qvGwKp.cjs → src-BDUsoOnL.cjs} +8 -8
- package/dist/shared/{src-CA0na5_d.mjs → src-CJu4NZI4.mjs} +198 -980
- package/dist/{src-D3kPdsBX.js → src-CBsKC-xF.js} +8 -8
- package/package.json +1 -1
- package/dist/shared/dist-DRt7s0oH.mjs +0 -147
|
@@ -121,7 +121,7 @@ type NullValue<T = void> = T | undefined | null | void;
|
|
|
121
121
|
type PartialNull<T> = { [P in keyof T] : T[P] | null };
|
|
122
122
|
type MakeAsync<Function_> = Function_ extends (this: infer This, ...parameters: infer Arguments) => infer Return ? (this: This, ...parameters: Arguments) => Return | Promise<Return> : never;
|
|
123
123
|
type MaybeArray<T> = T | T[];
|
|
124
|
-
type StringOrRegExp
|
|
124
|
+
type StringOrRegExp = string | RegExp;
|
|
125
125
|
|
|
126
126
|
//#endregion
|
|
127
127
|
//#region src/options/output-options.d.ts
|
|
@@ -226,7 +226,7 @@ interface OutputOptions {
|
|
|
226
226
|
* If `test` is a regular expression, the module whose id matches the regular expression will be captured.
|
|
227
227
|
* if `test` is empty, any module will be considered as matched.
|
|
228
228
|
*/
|
|
229
|
-
test?: StringOrRegExp
|
|
229
|
+
test?: StringOrRegExp
|
|
230
230
|
/**
|
|
231
231
|
* - Type: `number`
|
|
232
232
|
*
|
|
@@ -429,7 +429,7 @@ interface NormalizedOutputOptions {
|
|
|
429
429
|
|
|
430
430
|
//#endregion
|
|
431
431
|
//#region ../pluginutils/dist/index.d.ts
|
|
432
|
-
type StringOrRegExp = string | RegExp;
|
|
432
|
+
type StringOrRegExp$1 = string | RegExp;
|
|
433
433
|
type PluginModuleType = "js" | "jsx" | "ts" | "tsx" | "json" | "text" | "base64" | "dataurl" | "binary" | "empty" | (string & {});
|
|
434
434
|
type FilterExpression = And | Or | Not | Id | ModuleType$1 | Code | Query;
|
|
435
435
|
type TopLevelFilterExpression = Include | Exclude$1;
|
|
@@ -449,16 +449,16 @@ declare class Not {
|
|
|
449
449
|
constructor(expr: FilterExpression);
|
|
450
450
|
}
|
|
451
451
|
interface QueryFilterObject {
|
|
452
|
-
[key: string]: StringOrRegExp | boolean;
|
|
452
|
+
[key: string]: StringOrRegExp$1 | boolean;
|
|
453
453
|
}
|
|
454
454
|
interface IdParams {
|
|
455
455
|
cleanUrl?: boolean;
|
|
456
456
|
}
|
|
457
457
|
declare class Id {
|
|
458
458
|
kind: "id";
|
|
459
|
-
pattern: StringOrRegExp;
|
|
459
|
+
pattern: StringOrRegExp$1;
|
|
460
460
|
params: IdParams;
|
|
461
|
-
constructor(pattern: StringOrRegExp, params?: IdParams);
|
|
461
|
+
constructor(pattern: StringOrRegExp$1, params?: IdParams);
|
|
462
462
|
}
|
|
463
463
|
declare class ModuleType$1 {
|
|
464
464
|
kind: "moduleType";
|
|
@@ -467,14 +467,14 @@ declare class ModuleType$1 {
|
|
|
467
467
|
}
|
|
468
468
|
declare class Code {
|
|
469
469
|
kind: "code";
|
|
470
|
-
pattern: StringOrRegExp;
|
|
471
|
-
constructor(expr: StringOrRegExp);
|
|
470
|
+
pattern: StringOrRegExp$1;
|
|
471
|
+
constructor(expr: StringOrRegExp$1);
|
|
472
472
|
}
|
|
473
473
|
declare class Query {
|
|
474
474
|
kind: "query";
|
|
475
475
|
key: string;
|
|
476
|
-
pattern: StringOrRegExp | boolean;
|
|
477
|
-
constructor(key: string, pattern: StringOrRegExp | boolean);
|
|
476
|
+
pattern: StringOrRegExp$1 | boolean;
|
|
477
|
+
constructor(key: string, pattern: StringOrRegExp$1 | boolean);
|
|
478
478
|
}
|
|
479
479
|
declare class Include {
|
|
480
480
|
kind: "include";
|
|
@@ -489,10 +489,10 @@ declare class Exclude$1 {
|
|
|
489
489
|
declare function and(...args: FilterExpression[]): And;
|
|
490
490
|
declare function or(...args: FilterExpression[]): Or;
|
|
491
491
|
declare function not(expr: FilterExpression): Not;
|
|
492
|
-
declare function id(pattern: StringOrRegExp, params?: IdParams): Id;
|
|
492
|
+
declare function id(pattern: StringOrRegExp$1, params?: IdParams): Id;
|
|
493
493
|
declare function moduleType(pattern: PluginModuleType): ModuleType$1;
|
|
494
|
-
declare function code(pattern: StringOrRegExp): Code;
|
|
495
|
-
declare function query(key: string, pattern: StringOrRegExp | boolean): Query;
|
|
494
|
+
declare function code(pattern: StringOrRegExp$1): Code;
|
|
495
|
+
declare function query(key: string, pattern: StringOrRegExp$1 | boolean): Query;
|
|
496
496
|
declare function include(expr: FilterExpression): Include;
|
|
497
497
|
declare function exclude(expr: FilterExpression): Exclude$1;
|
|
498
498
|
/**
|
|
@@ -515,7 +515,7 @@ declare function queries(queryFilter: QueryFilterObject): And;
|
|
|
515
515
|
|
|
516
516
|
//#endregion
|
|
517
517
|
//#region src/plugin/hook-filter.d.ts
|
|
518
|
-
type GeneralHookFilter<Value = StringOrRegExp
|
|
518
|
+
type GeneralHookFilter<Value = StringOrRegExp> = MaybeArray<Value> | {
|
|
519
519
|
include?: MaybeArray<Value>
|
|
520
520
|
exclude?: MaybeArray<Value>
|
|
521
521
|
};
|
|
@@ -784,7 +784,7 @@ type OverrideFilterObject = {
|
|
|
784
784
|
transform?: HookFilterExtension<"transform">["filter"]
|
|
785
785
|
resolveId?: HookFilterExtension<"resolveId">["filter"]
|
|
786
786
|
load?: HookFilterExtension<"load">["filter"]
|
|
787
|
-
pluginNamePattern?: StringOrRegExp
|
|
787
|
+
pluginNamePattern?: StringOrRegExp[]
|
|
788
788
|
};
|
|
789
789
|
declare function withFilter<
|
|
790
790
|
A,
|
|
@@ -820,7 +820,7 @@ interface SourceDescription extends Partial<PartialNull<ModuleOptions>> {
|
|
|
820
820
|
interface ResolveIdExtraOptions {
|
|
821
821
|
custom?: CustomPluginOptions;
|
|
822
822
|
isEntry: boolean;
|
|
823
|
-
kind: "
|
|
823
|
+
kind: BindingHookResolveIdExtraArgs["kind"];
|
|
824
824
|
}
|
|
825
825
|
type ResolveIdResult = string | NullValue | false | PartialResolvedId;
|
|
826
826
|
type LoadResult = NullValue | string | SourceDescription;
|
|
@@ -978,7 +978,7 @@ interface ChecksOptions {
|
|
|
978
978
|
//#region src/options/input-options.d.ts
|
|
979
979
|
type InputOption = string | string[] | Record<string, string>;
|
|
980
980
|
type OxcTransformOption = Omit<TransformOptions, "sourceType" | "lang" | "cwd" | "sourcemap" | "define" | "inject">;
|
|
981
|
-
type ExternalOption = StringOrRegExp
|
|
981
|
+
type ExternalOption = StringOrRegExp | StringOrRegExp[] | ((id: string, parentId: string | undefined, isResolved: boolean) => NullValue<boolean>);
|
|
982
982
|
type ModuleTypes = Record<string, "js" | "jsx" | "ts" | "tsx" | "json" | "text" | "base64" | "dataurl" | "binary" | "empty" | "css" | "asset">;
|
|
983
983
|
interface WatcherOptions {
|
|
984
984
|
skipWrite?: boolean;
|
|
@@ -987,8 +987,8 @@ interface WatcherOptions {
|
|
|
987
987
|
pollInterval?: number
|
|
988
988
|
compareContents?: boolean
|
|
989
989
|
};
|
|
990
|
-
include?: StringOrRegExp
|
|
991
|
-
exclude?: StringOrRegExp
|
|
990
|
+
include?: StringOrRegExp | StringOrRegExp[];
|
|
991
|
+
exclude?: StringOrRegExp | StringOrRegExp[];
|
|
992
992
|
}
|
|
993
993
|
type MakeAbsoluteExternalsRelative = boolean | "ifRelativeSource";
|
|
994
994
|
type HmrOptions = boolean | {
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
import { __esm } from "./chunk-DSsiIF1Z.mjs";
|
|
2
|
+
|
|
3
|
+
//#region src/utils/misc.ts
|
|
4
|
+
function arraify(value) {
|
|
5
|
+
return Array.isArray(value) ? value : [value];
|
|
6
|
+
}
|
|
7
|
+
function isNullish(value) {
|
|
8
|
+
return value === null || value === void 0;
|
|
9
|
+
}
|
|
10
|
+
function isPromiseLike(value) {
|
|
11
|
+
return value && (typeof value === "object" || typeof value === "function") && typeof value.then === "function";
|
|
12
|
+
}
|
|
13
|
+
function unimplemented(info) {
|
|
14
|
+
if (info) throw new Error(`unimplemented: ${info}`);
|
|
15
|
+
throw new Error("unimplemented");
|
|
16
|
+
}
|
|
17
|
+
function unreachable(info) {
|
|
18
|
+
if (info) throw new Error(`unreachable: ${info}`);
|
|
19
|
+
throw new Error("unreachable");
|
|
20
|
+
}
|
|
21
|
+
function unsupported(info) {
|
|
22
|
+
throw new Error(`UNSUPPORTED: ${info}`);
|
|
23
|
+
}
|
|
24
|
+
function noop(..._args) {}
|
|
25
|
+
var init_misc = __esm({ "src/utils/misc.ts"() {} });
|
|
26
|
+
|
|
27
|
+
//#endregion
|
|
28
|
+
//#region ../pluginutils/dist/index.js
|
|
29
|
+
function and(...args) {
|
|
30
|
+
return new And(...args);
|
|
31
|
+
}
|
|
32
|
+
function or(...args) {
|
|
33
|
+
return new Or(...args);
|
|
34
|
+
}
|
|
35
|
+
function not(expr) {
|
|
36
|
+
return new Not(expr);
|
|
37
|
+
}
|
|
38
|
+
function id(pattern, params) {
|
|
39
|
+
return new Id(pattern, params);
|
|
40
|
+
}
|
|
41
|
+
function moduleType(pattern) {
|
|
42
|
+
return new ModuleType(pattern);
|
|
43
|
+
}
|
|
44
|
+
function code(pattern) {
|
|
45
|
+
return new Code(pattern);
|
|
46
|
+
}
|
|
47
|
+
function query(key, pattern) {
|
|
48
|
+
return new Query(key, pattern);
|
|
49
|
+
}
|
|
50
|
+
function include(expr) {
|
|
51
|
+
return new Include(expr);
|
|
52
|
+
}
|
|
53
|
+
function exclude(expr) {
|
|
54
|
+
return new Exclude(expr);
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* convert a queryObject to FilterExpression like
|
|
58
|
+
* ```js
|
|
59
|
+
* and(query(k1, v1), query(k2, v2))
|
|
60
|
+
* ```
|
|
61
|
+
* @param queryFilterObject The query filter object needs to be matched.
|
|
62
|
+
* @returns a `And` FilterExpression
|
|
63
|
+
*/
|
|
64
|
+
function queries(queryFilter) {
|
|
65
|
+
let arr = Object.entries(queryFilter).map(([key, value]) => {
|
|
66
|
+
return new Query(key, value);
|
|
67
|
+
});
|
|
68
|
+
return and(...arr);
|
|
69
|
+
}
|
|
70
|
+
var And, Or, Not, Id, ModuleType, Code, Query, Include, Exclude;
|
|
71
|
+
var init_dist = __esm({ "../pluginutils/dist/index.js"() {
|
|
72
|
+
And = class {
|
|
73
|
+
kind;
|
|
74
|
+
args;
|
|
75
|
+
constructor(...args) {
|
|
76
|
+
if (args.length === 0) throw new Error("`And` expects at least one operand");
|
|
77
|
+
this.args = args;
|
|
78
|
+
this.kind = "and";
|
|
79
|
+
}
|
|
80
|
+
};
|
|
81
|
+
Or = class {
|
|
82
|
+
kind;
|
|
83
|
+
args;
|
|
84
|
+
constructor(...args) {
|
|
85
|
+
if (args.length === 0) throw new Error("`Or` expects at least one operand");
|
|
86
|
+
this.args = args;
|
|
87
|
+
this.kind = "or";
|
|
88
|
+
}
|
|
89
|
+
};
|
|
90
|
+
Not = class {
|
|
91
|
+
kind;
|
|
92
|
+
expr;
|
|
93
|
+
constructor(expr) {
|
|
94
|
+
this.expr = expr;
|
|
95
|
+
this.kind = "not";
|
|
96
|
+
}
|
|
97
|
+
};
|
|
98
|
+
Id = class {
|
|
99
|
+
kind;
|
|
100
|
+
pattern;
|
|
101
|
+
params;
|
|
102
|
+
constructor(pattern, params) {
|
|
103
|
+
this.pattern = pattern;
|
|
104
|
+
this.kind = "id";
|
|
105
|
+
this.params = params ?? { cleanUrl: false };
|
|
106
|
+
}
|
|
107
|
+
};
|
|
108
|
+
ModuleType = class {
|
|
109
|
+
kind;
|
|
110
|
+
pattern;
|
|
111
|
+
constructor(pattern) {
|
|
112
|
+
this.pattern = pattern;
|
|
113
|
+
this.kind = "moduleType";
|
|
114
|
+
}
|
|
115
|
+
};
|
|
116
|
+
Code = class {
|
|
117
|
+
kind;
|
|
118
|
+
pattern;
|
|
119
|
+
constructor(expr) {
|
|
120
|
+
this.pattern = expr;
|
|
121
|
+
this.kind = "code";
|
|
122
|
+
}
|
|
123
|
+
};
|
|
124
|
+
Query = class {
|
|
125
|
+
kind;
|
|
126
|
+
key;
|
|
127
|
+
pattern;
|
|
128
|
+
constructor(key, pattern) {
|
|
129
|
+
this.pattern = pattern;
|
|
130
|
+
this.key = key;
|
|
131
|
+
this.kind = "query";
|
|
132
|
+
}
|
|
133
|
+
};
|
|
134
|
+
Include = class {
|
|
135
|
+
kind;
|
|
136
|
+
expr;
|
|
137
|
+
constructor(expr) {
|
|
138
|
+
this.expr = expr;
|
|
139
|
+
this.kind = "include";
|
|
140
|
+
}
|
|
141
|
+
};
|
|
142
|
+
Exclude = class {
|
|
143
|
+
kind;
|
|
144
|
+
expr;
|
|
145
|
+
constructor(expr) {
|
|
146
|
+
this.expr = expr;
|
|
147
|
+
this.kind = "exclude";
|
|
148
|
+
}
|
|
149
|
+
};
|
|
150
|
+
} });
|
|
151
|
+
|
|
152
|
+
//#endregion
|
|
153
|
+
export { and as and$1, arraify, code as code$1, exclude as exclude$1, id as id$1, include as include$1, init_dist, init_misc, isNullish, isPromiseLike, moduleType as moduleType$1, noop, not as not$1, or as or$1, queries as queries$1, query as query$1, unimplemented, unreachable, unsupported };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __esm } from "./chunk-DSsiIF1Z.mjs";
|
|
2
|
-
import { init_rolldown, rolldown } from "./src-
|
|
2
|
+
import { init_rolldown, rolldown } from "./src-CJu4NZI4.mjs";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import { pathToFileURL } from "node:url";
|
|
5
5
|
import { cwd } from "node:process";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const require_chunk = require('./chunk-DDkG_k5U.cjs');
|
|
2
|
-
const require_src = require('./src-
|
|
2
|
+
const require_src = require('./src-BDUsoOnL.cjs');
|
|
3
3
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
4
4
|
const node_url = require_chunk.__toESM(require("node:url"));
|
|
5
5
|
const node_process = require_chunk.__toESM(require("node:process"));
|
|
@@ -10,9 +10,6 @@ function spaces(index) {
|
|
|
10
10
|
function tabsToSpaces(value) {
|
|
11
11
|
return value.replace(/^\t+/, (match) => match.split(" ").join(" "));
|
|
12
12
|
}
|
|
13
|
-
const LINE_TRUNCATE_LENGTH = 120;
|
|
14
|
-
const MIN_CHARACTERS_SHOWN_AFTER_LOCATION = 10;
|
|
15
|
-
const ELLIPSIS = "...";
|
|
16
13
|
function getCodeFrame(source, line, column) {
|
|
17
14
|
let lines = source.split("\n");
|
|
18
15
|
if (line > lines.length) return "";
|
|
@@ -38,6 +35,12 @@ function getCodeFrame(source, line, column) {
|
|
|
38
35
|
return `${lineNumber}: ${displayedLine}`;
|
|
39
36
|
}).join("\n");
|
|
40
37
|
}
|
|
38
|
+
var LINE_TRUNCATE_LENGTH, MIN_CHARACTERS_SHOWN_AFTER_LOCATION, ELLIPSIS;
|
|
39
|
+
var init_code_frame = __esm({ "src/utils/code-frame.ts"() {
|
|
40
|
+
LINE_TRUNCATE_LENGTH = 120;
|
|
41
|
+
MIN_CHARACTERS_SHOWN_AFTER_LOCATION = 10;
|
|
42
|
+
ELLIPSIS = "...";
|
|
43
|
+
} });
|
|
41
44
|
|
|
42
45
|
//#endregion
|
|
43
46
|
//#region src/log/locate-character/index.js
|
|
@@ -99,6 +102,7 @@ function getLocator(source, options = {}) {
|
|
|
99
102
|
function locate(source, search, options) {
|
|
100
103
|
return getLocator(source, options)(search, options && options.startIndex);
|
|
101
104
|
}
|
|
105
|
+
var init_locate_character = __esm({ "src/log/locate-character/index.js"() {} });
|
|
102
106
|
|
|
103
107
|
//#endregion
|
|
104
108
|
//#region src/log/logs.ts
|
|
@@ -180,6 +184,8 @@ function augmentCodeLocation(properties, pos, source, id) {
|
|
|
180
184
|
}
|
|
181
185
|
var INVALID_LOG_POSITION, PLUGIN_ERROR, INPUT_HOOK_IN_OUTPUT_PLUGIN, CYCLE_LOADING, MULTIPLY_NOTIFY_OPTION, PARSE_ERROR;
|
|
182
186
|
var init_logs = __esm({ "src/log/logs.ts"() {
|
|
187
|
+
init_code_frame();
|
|
188
|
+
init_locate_character();
|
|
183
189
|
INVALID_LOG_POSITION = "INVALID_LOG_POSITION", PLUGIN_ERROR = "PLUGIN_ERROR", INPUT_HOOK_IN_OUTPUT_PLUGIN = "INPUT_HOOK_IN_OUTPUT_PLUGIN", CYCLE_LOADING = "CYCLE_LOADING", MULTIPLY_NOTIFY_OPTION = "MULTIPLY_NOTIFY_OPTION", PARSE_ERROR = "PARSE_ERROR";
|
|
184
190
|
} });
|
|
185
191
|
|
|
@@ -219,6 +225,7 @@ function applyFix(program, fixPath) {
|
|
|
219
225
|
node.value = RegExp(node.regex.pattern, node.regex.flags);
|
|
220
226
|
} catch (_err) {}
|
|
221
227
|
}
|
|
228
|
+
var init_wrap = __esm({ "../../node_modules/.pnpm/oxc-parser@0.72.0/node_modules/oxc-parser/wrap.mjs"() {} });
|
|
222
229
|
|
|
223
230
|
//#endregion
|
|
224
231
|
//#region src/parse-ast-index.ts
|
|
@@ -257,7 +264,10 @@ async function parseAstAsync(sourceText, options, filename) {
|
|
|
257
264
|
}
|
|
258
265
|
var defaultParserOptions;
|
|
259
266
|
var init_parse_ast_index = __esm({ "src/parse-ast-index.ts"() {
|
|
267
|
+
init_locate_character();
|
|
260
268
|
init_logs();
|
|
269
|
+
init_code_frame();
|
|
270
|
+
init_wrap();
|
|
261
271
|
defaultParserOptions = {
|
|
262
272
|
lang: "js",
|
|
263
273
|
preserveParens: false
|
|
@@ -9,7 +9,7 @@ const node_os = require_chunk.__toESM(require("node:os"));
|
|
|
9
9
|
const node_worker_threads = require_chunk.__toESM(require("node:worker_threads"));
|
|
10
10
|
|
|
11
11
|
//#region package.json
|
|
12
|
-
var version = "1.0.0-beta.9-commit.
|
|
12
|
+
var version = "1.0.0-beta.9-commit.b174110";
|
|
13
13
|
var description$1 = "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.";
|
|
14
14
|
|
|
15
15
|
//#endregion
|
|
@@ -2161,7 +2161,7 @@ var NormalizedInputOptionsImpl = class {
|
|
|
2161
2161
|
|
|
2162
2162
|
//#endregion
|
|
2163
2163
|
//#region src/types/sourcemap.ts
|
|
2164
|
-
function bindingifySourcemap
|
|
2164
|
+
function bindingifySourcemap(map) {
|
|
2165
2165
|
if (map == null) return;
|
|
2166
2166
|
return { inner: typeof map === "string" ? map : {
|
|
2167
2167
|
file: map.file ?? void 0,
|
|
@@ -2705,7 +2705,7 @@ function bindingifyTransform(args$1) {
|
|
|
2705
2705
|
});
|
|
2706
2706
|
return {
|
|
2707
2707
|
code: ret.code,
|
|
2708
|
-
map: bindingifySourcemap
|
|
2708
|
+
map: bindingifySourcemap(normalizeTransformHookSourcemap(id$1, code$1, ret.map)),
|
|
2709
2709
|
sideEffects: bindingifySideEffects(moduleOption.moduleSideEffects),
|
|
2710
2710
|
moduleType: ret.moduleType
|
|
2711
2711
|
};
|
|
@@ -2731,7 +2731,7 @@ function bindingifyLoad(args$1) {
|
|
|
2731
2731
|
let map = preProcessSourceMap(ret, id$1);
|
|
2732
2732
|
return {
|
|
2733
2733
|
code: ret.code,
|
|
2734
|
-
map: bindingifySourcemap
|
|
2734
|
+
map: bindingifySourcemap(map),
|
|
2735
2735
|
moduleType: ret.moduleType,
|
|
2736
2736
|
sideEffects: bindingifySideEffects(moduleOption.moduleSideEffects)
|
|
2737
2737
|
};
|
|
@@ -2837,7 +2837,7 @@ function bindingifyOutputOptions(outputOptions) {
|
|
|
2837
2837
|
format: bindingifyFormat(format),
|
|
2838
2838
|
exports: exports$1,
|
|
2839
2839
|
hashCharacters,
|
|
2840
|
-
sourcemap: bindingifySourcemap(sourcemap),
|
|
2840
|
+
sourcemap: bindingifySourcemap$1(sourcemap),
|
|
2841
2841
|
sourcemapDebugIds,
|
|
2842
2842
|
sourcemapIgnoreList: bindingifySourcemapIgnoreList(sourcemapIgnoreList),
|
|
2843
2843
|
sourcemapPathTransform,
|
|
@@ -2887,7 +2887,7 @@ function bindingifyFormat(format) {
|
|
|
2887
2887
|
default: require_dist.unimplemented(`output.format: ${format}`);
|
|
2888
2888
|
}
|
|
2889
2889
|
}
|
|
2890
|
-
function bindingifySourcemap(sourcemap) {
|
|
2890
|
+
function bindingifySourcemap$1(sourcemap) {
|
|
2891
2891
|
switch (sourcemap) {
|
|
2892
2892
|
case true: return "file";
|
|
2893
2893
|
case "inline": return "inline";
|
|
@@ -3153,7 +3153,7 @@ function collectChangedBundle(changed, bundle) {
|
|
|
3153
3153
|
facadeModuleId: item.facadeModuleId || void 0,
|
|
3154
3154
|
isDynamicEntry: item.isDynamicEntry,
|
|
3155
3155
|
moduleIds: item.moduleIds,
|
|
3156
|
-
map: bindingifySourcemap
|
|
3156
|
+
map: bindingifySourcemap(item.map),
|
|
3157
3157
|
sourcemapFilename: item.sourcemapFileName || void 0,
|
|
3158
3158
|
preliminaryFilename: item.preliminaryFileName
|
|
3159
3159
|
});
|
|
@@ -3191,7 +3191,7 @@ function bindingifyRenderChunk(args$1) {
|
|
|
3191
3191
|
if (!ret.map) return { code: ret.code };
|
|
3192
3192
|
return {
|
|
3193
3193
|
code: ret.code,
|
|
3194
|
-
map: bindingifySourcemap
|
|
3194
|
+
map: bindingifySourcemap(ret.map)
|
|
3195
3195
|
};
|
|
3196
3196
|
},
|
|
3197
3197
|
meta: bindingifyPluginHookMeta(meta),
|