@rolldown/browser 1.0.0-beta.8-commit.d53650c → 1.0.0-beta.8-commit.165d0b1
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/browser.mjs +32 -39
- package/dist/cli.cjs +8 -6
- package/dist/cli.mjs +8 -6
- package/dist/experimental-index.cjs +2 -2
- package/dist/experimental-index.d.cts +2 -2
- package/dist/experimental-index.d.mts +2 -2
- package/dist/experimental-index.mjs +2 -2
- package/dist/index.cjs +2 -2
- package/dist/index.d.cts +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.mjs +2 -2
- package/dist/parallel-plugin-worker.cjs +2 -2
- package/dist/parallel-plugin-worker.mjs +2 -2
- package/dist/parallel-plugin.d.cts +1 -1
- package/dist/parallel-plugin.d.mts +1 -1
- package/dist/parse-ast-index.cjs +1 -1
- package/dist/parse-ast-index.mjs +1 -1
- package/dist/rolldown-binding.wasm32-wasi.wasm +0 -0
- package/dist/shared/{input-options.d-CJIzCDlR.d.mts → input-options.d-BZRlmV0Y.d.mts} +9 -8
- package/dist/shared/{input-options.d-sjdx_aVw.d.cts → input-options.d-IUq3nQ6k.d.cts} +9 -8
- package/dist/shared/{parse-ast-index-BoNJRs1a.mjs → parse-ast-index-Cprsj_YY.mjs} +12 -9
- package/dist/shared/{parse-ast-index-DPj-F51D.cjs → parse-ast-index-DAk8Z2V8.cjs} +11 -8
- package/dist/shared/{src-ChSCQKWy.cjs → src-BYzJDqvj.cjs} +25 -38
- package/dist/shared/{src-DN93t15D.mjs → src-Bkj32aeI.mjs} +25 -43
- package/package.json +3 -3
package/dist/browser.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import colors from "ansis";
|
|
|
5
5
|
import * as v from "valibot";
|
|
6
6
|
|
|
7
7
|
//#region package.json
|
|
8
|
-
var version = "1.0.0-beta.8-commit.
|
|
8
|
+
var version = "1.0.0-beta.8-commit.165d0b1";
|
|
9
9
|
|
|
10
10
|
//#endregion
|
|
11
11
|
//#region src/builtin-plugin/utils.ts
|
|
@@ -197,13 +197,16 @@ function logMultiplyNotifyOption() {
|
|
|
197
197
|
};
|
|
198
198
|
}
|
|
199
199
|
function logPluginError(error$1, plugin, { hook, id } = {}) {
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
200
|
+
try {
|
|
201
|
+
const code = error$1.code;
|
|
202
|
+
if (!error$1.pluginCode && code != null && (typeof code !== "string" || !code.startsWith("PLUGIN_"))) error$1.pluginCode = code;
|
|
203
|
+
error$1.code = PLUGIN_ERROR;
|
|
204
|
+
error$1.plugin = plugin;
|
|
205
|
+
if (hook) error$1.hook = hook;
|
|
206
|
+
if (id) error$1.id = id;
|
|
207
|
+
} catch (_) {} finally {
|
|
208
|
+
return error$1;
|
|
209
|
+
}
|
|
207
210
|
}
|
|
208
211
|
function error(base) {
|
|
209
212
|
if (!(base instanceof Error)) {
|
|
@@ -653,10 +656,9 @@ const ChecksOptionsSchema = v.strictObject({
|
|
|
653
656
|
configurationFieldConflict: v.pipe(v.optional(v.boolean()), v.description("Whether to emit warning when detecting configuration field conflict"))
|
|
654
657
|
});
|
|
655
658
|
const MinifyOptionsSchema = v.strictObject({
|
|
656
|
-
mangle: v.boolean(),
|
|
657
|
-
compress: v.boolean(),
|
|
658
|
-
|
|
659
|
-
removeWhitespace: v.boolean()
|
|
659
|
+
mangle: v.optional(v.boolean()),
|
|
660
|
+
compress: v.optional(v.boolean()),
|
|
661
|
+
removeWhitespace: v.optional(v.boolean())
|
|
660
662
|
});
|
|
661
663
|
const ResolveOptionsSchema = v.strictObject({
|
|
662
664
|
alias: v.optional(v.record(v.string(), v.union([v.string(), v.array(v.string())]))),
|
|
@@ -839,8 +841,13 @@ const OutputOptionsSchema = v.strictObject({
|
|
|
839
841
|
inlineDynamicImports: v.pipe(v.optional(v.boolean()), v.description("Inline dynamic imports")),
|
|
840
842
|
advancedChunks: v.optional(AdvancedChunksSchema),
|
|
841
843
|
comments: v.pipe(v.optional(v.union([v.literal("none"), v.literal("preserve-legal")])), v.description("Control comments in the output")),
|
|
844
|
+
plugins: v.optional(v.custom(() => true)),
|
|
845
|
+
polyfillRequire: v.pipe(v.optional(v.boolean()), v.description("Disable require polyfill injection")),
|
|
842
846
|
target: v.pipe(v.optional(v.enum(ESTarget)), v.description("The JavaScript target environment")),
|
|
843
|
-
|
|
847
|
+
hoistTransitiveImports: v.optional(v.custom((input) => {
|
|
848
|
+
if (input) return false;
|
|
849
|
+
return true;
|
|
850
|
+
}, () => `The 'true' value is not supported`))
|
|
844
851
|
});
|
|
845
852
|
const getAddonDescription = (placement, wrapper) => {
|
|
846
853
|
return `Code to insert the ${colors.bold(placement)} of the bundled file (${colors.bold(wrapper)} the wrapper function)`;
|
|
@@ -870,7 +877,8 @@ const OutputCliOptionsSchema = v.omit(v.strictObject({
|
|
|
870
877
|
}), [
|
|
871
878
|
"sourcemapIgnoreList",
|
|
872
879
|
"sourcemapPathTransform",
|
|
873
|
-
"plugins"
|
|
880
|
+
"plugins",
|
|
881
|
+
"hoistTransitiveImports"
|
|
874
882
|
]);
|
|
875
883
|
const CliOptionsSchema = v.strictObject({
|
|
876
884
|
config: v.pipe(v.optional(v.union([v.string(), v.boolean()])), v.description("Path to the config file (default: `rolldown.config.js`)")),
|
|
@@ -1003,24 +1011,6 @@ function joinNewLine(s1, s2) {
|
|
|
1003
1011
|
return s1.replace(/\n+$/, "") + "\n" + s2.replace(/^\n+/, "");
|
|
1004
1012
|
}
|
|
1005
1013
|
|
|
1006
|
-
//#endregion
|
|
1007
|
-
//#region src/utils/resolved-external.ts
|
|
1008
|
-
function transformResolvedExternal(bindingResolvedExternal$1) {
|
|
1009
|
-
switch (bindingResolvedExternal$1.type) {
|
|
1010
|
-
case "Bool": return bindingResolvedExternal$1.field0;
|
|
1011
|
-
case "Absolute": return "absolute";
|
|
1012
|
-
case "Relative": unreachable(`The PluginContext resolve result external couldn't be 'relative'`);
|
|
1013
|
-
}
|
|
1014
|
-
}
|
|
1015
|
-
function bindingResolvedExternal(external) {
|
|
1016
|
-
if (typeof external === "boolean") return {
|
|
1017
|
-
type: "Bool",
|
|
1018
|
-
field0: external
|
|
1019
|
-
};
|
|
1020
|
-
if (external === "absolute") return { type: "Absolute" };
|
|
1021
|
-
if (external === "relative") return { type: "Relative" };
|
|
1022
|
-
}
|
|
1023
|
-
|
|
1024
1014
|
//#endregion
|
|
1025
1015
|
//#region src/utils/transform-module-info.ts
|
|
1026
1016
|
function transformModuleInfo(info, option) {
|
|
@@ -1115,7 +1105,7 @@ function bindingPluginOrder(order) {
|
|
|
1115
1105
|
}
|
|
1116
1106
|
|
|
1117
1107
|
//#endregion
|
|
1118
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
1108
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.66.0/node_modules/oxc-parser/wrap.mjs
|
|
1119
1109
|
function wrap$1(result) {
|
|
1120
1110
|
let program, module, comments, errors;
|
|
1121
1111
|
return {
|
|
@@ -1252,7 +1242,7 @@ var PluginContextImpl = class extends MinimalPluginContextImpl {
|
|
|
1252
1242
|
const info = this.data.getModuleOption(res.id) || {};
|
|
1253
1243
|
return {
|
|
1254
1244
|
...res,
|
|
1255
|
-
external:
|
|
1245
|
+
external: res.external === "relative" ? unreachable(`The PluginContext resolve result external couldn't be 'relative'`) : res.external,
|
|
1256
1246
|
...info
|
|
1257
1247
|
};
|
|
1258
1248
|
}
|
|
@@ -1360,7 +1350,7 @@ function bindingifyResolveId(args) {
|
|
|
1360
1350
|
if (ret == null) return;
|
|
1361
1351
|
if (ret === false) return {
|
|
1362
1352
|
id: specifier,
|
|
1363
|
-
external:
|
|
1353
|
+
external: true,
|
|
1364
1354
|
normalizeExternalId: true
|
|
1365
1355
|
};
|
|
1366
1356
|
if (typeof ret === "string") return {
|
|
@@ -1374,7 +1364,7 @@ function bindingifyResolveId(args) {
|
|
|
1374
1364
|
});
|
|
1375
1365
|
return {
|
|
1376
1366
|
id: ret.id,
|
|
1377
|
-
external:
|
|
1367
|
+
external: ret.external,
|
|
1378
1368
|
normalizeExternalId: false,
|
|
1379
1369
|
sideEffects: bindingifySideEffects(exist.moduleSideEffects)
|
|
1380
1370
|
};
|
|
@@ -1393,12 +1383,12 @@ function bindingifyResolveDynamicImport(args) {
|
|
|
1393
1383
|
if (ret == null) return;
|
|
1394
1384
|
if (ret === false) return {
|
|
1395
1385
|
id: specifier,
|
|
1396
|
-
external:
|
|
1386
|
+
external: true
|
|
1397
1387
|
};
|
|
1398
1388
|
if (typeof ret === "string") return { id: ret };
|
|
1399
1389
|
const result = {
|
|
1400
1390
|
id: ret.id,
|
|
1401
|
-
external:
|
|
1391
|
+
external: ret.external
|
|
1402
1392
|
};
|
|
1403
1393
|
if (ret.moduleSideEffects !== null) result.sideEffects = bindingifySideEffects(ret.moduleSideEffects);
|
|
1404
1394
|
args.pluginContextData.updateModuleOption(ret.id, {
|
|
@@ -2316,9 +2306,12 @@ var PluginContextData = class {
|
|
|
2316
2306
|
//#region src/utils/normalize-string-or-regex.ts
|
|
2317
2307
|
function normalizedStringOrRegex(pattern) {
|
|
2318
2308
|
if (!pattern) return void 0;
|
|
2319
|
-
if (!
|
|
2309
|
+
if (!isReadonlyArray(pattern)) return [pattern];
|
|
2320
2310
|
return pattern;
|
|
2321
2311
|
}
|
|
2312
|
+
function isReadonlyArray(input) {
|
|
2313
|
+
return Array.isArray(input);
|
|
2314
|
+
}
|
|
2322
2315
|
|
|
2323
2316
|
//#endregion
|
|
2324
2317
|
//#region src/utils/bindingify-input-options.ts
|
package/dist/cli.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const require_chunk = require('./shared/chunk-qZFfknuJ.cjs');
|
|
2
|
-
const require_src = require('./shared/src-
|
|
3
|
-
require('./shared/parse-ast-index-
|
|
2
|
+
const require_src = require('./shared/src-BYzJDqvj.cjs');
|
|
3
|
+
require('./shared/parse-ast-index-DAk8Z2V8.cjs');
|
|
4
4
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
5
5
|
const ansis = require_chunk.__toESM(require("ansis"));
|
|
6
6
|
const node_process = require_chunk.__toESM(require("node:process"));
|
|
@@ -1559,8 +1559,8 @@ async function loadConfig(configPath) {
|
|
|
1559
1559
|
}
|
|
1560
1560
|
|
|
1561
1561
|
//#endregion
|
|
1562
|
-
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.
|
|
1563
|
-
var require_usingCtx = require_chunk.__commonJS({ "../../node_modules/.pnpm/@oxc-project+runtime@0.
|
|
1562
|
+
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.66.0/node_modules/@oxc-project/runtime/src/helpers/usingCtx.js
|
|
1563
|
+
var require_usingCtx = require_chunk.__commonJS({ "../../node_modules/.pnpm/@oxc-project+runtime@0.66.0/node_modules/@oxc-project/runtime/src/helpers/usingCtx.js"(exports, module) {
|
|
1564
1564
|
function _usingCtx() {
|
|
1565
1565
|
var r$1 = "function" == typeof SuppressedError ? SuppressedError : function(r$2, e$1) {
|
|
1566
1566
|
var n$2 = Error();
|
|
@@ -1622,6 +1622,10 @@ var import_usingCtx = require_chunk.__toESM(require_usingCtx());
|
|
|
1622
1622
|
//#endregion
|
|
1623
1623
|
//#region src/cli/commands/bundle.ts
|
|
1624
1624
|
async function bundleWithConfig(configPath, cliOptions) {
|
|
1625
|
+
if (cliOptions.watch) {
|
|
1626
|
+
process.env.ROLLUP_WATCH = "true";
|
|
1627
|
+
process.env.ROLLDOWN_WATCH = "true";
|
|
1628
|
+
}
|
|
1625
1629
|
const config = await loadConfig(configPath);
|
|
1626
1630
|
if (!config) {
|
|
1627
1631
|
logger.error(`No configuration found at ${config}`);
|
|
@@ -1659,8 +1663,6 @@ async function bundleWithCliOptions(cliOptions) {
|
|
|
1659
1663
|
}
|
|
1660
1664
|
}
|
|
1661
1665
|
async function watchInner(config, cliOptions) {
|
|
1662
|
-
process.env.ROLLUP_WATCH = "true";
|
|
1663
|
-
process.env.ROLLDOWN_WATCH = "true";
|
|
1664
1666
|
let normalizedConfig = require_src.arraify(config).map((option) => {
|
|
1665
1667
|
return {
|
|
1666
1668
|
...option,
|
package/dist/cli.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __commonJS, __esm, __toESM } from "./shared/chunk-DSsiIF1Z.mjs";
|
|
2
|
-
import { arraify, description, getInputCliKeys, getJsonSchema, getOutputCliKeys, init_misc, init_rolldown, init_validator, init_watch, rolldown, validateCliOptions, version, watch } from "./shared/src-
|
|
3
|
-
import "./shared/parse-ast-index-
|
|
2
|
+
import { arraify, description, getInputCliKeys, getJsonSchema, getOutputCliKeys, init_misc, init_rolldown, init_validator, init_watch, rolldown, validateCliOptions, version, watch } from "./shared/src-Bkj32aeI.mjs";
|
|
3
|
+
import "./shared/parse-ast-index-Cprsj_YY.mjs";
|
|
4
4
|
import path, { sep } from "node:path";
|
|
5
5
|
import colors from "ansis";
|
|
6
6
|
import process$1, { cwd } from "node:process";
|
|
@@ -1564,8 +1564,8 @@ var init_load_config = __esm({ "src/cli/load-config.ts"() {
|
|
|
1564
1564
|
} });
|
|
1565
1565
|
|
|
1566
1566
|
//#endregion
|
|
1567
|
-
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.
|
|
1568
|
-
var require_usingCtx = __commonJS({ "../../node_modules/.pnpm/@oxc-project+runtime@0.
|
|
1567
|
+
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.66.0/node_modules/@oxc-project/runtime/src/helpers/usingCtx.js
|
|
1568
|
+
var require_usingCtx = __commonJS({ "../../node_modules/.pnpm/@oxc-project+runtime@0.66.0/node_modules/@oxc-project/runtime/src/helpers/usingCtx.js"(exports, module) {
|
|
1569
1569
|
function _usingCtx() {
|
|
1570
1570
|
var r$1 = "function" == typeof SuppressedError ? SuppressedError : function(r$2, e$1) {
|
|
1571
1571
|
var n$2 = Error();
|
|
@@ -1627,6 +1627,10 @@ var import_usingCtx = __toESM(require_usingCtx());
|
|
|
1627
1627
|
//#endregion
|
|
1628
1628
|
//#region src/cli/commands/bundle.ts
|
|
1629
1629
|
async function bundleWithConfig(configPath, cliOptions) {
|
|
1630
|
+
if (cliOptions.watch) {
|
|
1631
|
+
process.env.ROLLUP_WATCH = "true";
|
|
1632
|
+
process.env.ROLLDOWN_WATCH = "true";
|
|
1633
|
+
}
|
|
1630
1634
|
const config = await loadConfig(configPath);
|
|
1631
1635
|
if (!config) {
|
|
1632
1636
|
logger.error(`No configuration found at ${config}`);
|
|
@@ -1664,8 +1668,6 @@ async function bundleWithCliOptions(cliOptions) {
|
|
|
1664
1668
|
}
|
|
1665
1669
|
}
|
|
1666
1670
|
async function watchInner(config, cliOptions) {
|
|
1667
|
-
process.env.ROLLUP_WATCH = "true";
|
|
1668
|
-
process.env.ROLLDOWN_WATCH = "true";
|
|
1669
1671
|
let normalizedConfig = arraify(config).map((option) => {
|
|
1670
1672
|
return {
|
|
1671
1673
|
...option,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const require_chunk = require('./shared/chunk-qZFfknuJ.cjs');
|
|
3
|
-
const require_src = require('./shared/src-
|
|
4
|
-
require('./shared/parse-ast-index-
|
|
3
|
+
const require_src = require('./shared/src-BYzJDqvj.cjs');
|
|
4
|
+
require('./shared/parse-ast-index-DAk8Z2V8.cjs');
|
|
5
5
|
const src_rolldown_binding_wasi_cjs = require_chunk.__toESM(require("./rolldown-binding.wasi.cjs"));
|
|
6
6
|
const node_url = require_chunk.__toESM(require("node:url"));
|
|
7
7
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BuiltinPlugin, InputOptions, RolldownPlugin, buildImportAnalysisPlugin, defineParallelPlugin, dynamicImportVarsPlugin, importGlobPlugin, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, reportPlugin, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin } from "./shared/input-options.d-
|
|
1
|
+
import { BuiltinPlugin, InputOptions, RolldownPlugin, buildImportAnalysisPlugin, defineParallelPlugin, dynamicImportVarsPlugin, importGlobPlugin, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, reportPlugin, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin } from "./shared/input-options.d-IUq3nQ6k.cjs";
|
|
2
2
|
import { BindingReplacePluginConfig, BindingTransformPluginConfig, TransformOptions, TransformResult, moduleRunnerTransform, transform } from "./rolldown-binding.wasi.cjs";
|
|
3
3
|
|
|
4
4
|
//#region src/api/experimental.d.ts
|
|
@@ -83,7 +83,7 @@ declare function replacePlugin(values?: BindingReplacePluginConfig["values"], op
|
|
|
83
83
|
|
|
84
84
|
//#endregion
|
|
85
85
|
//#region src/builtin-plugin/transform-plugin.d.ts
|
|
86
|
-
type TransformPattern = string | RegExp | (RegExp | string)[];
|
|
86
|
+
type TransformPattern = string | RegExp | readonly (RegExp | string)[];
|
|
87
87
|
type TransformPluginConfig = Omit<BindingTransformPluginConfig, "include" | "exclude" | "jsxRefreshInclude" | "jsxRefreshExclude"> & {
|
|
88
88
|
include?: TransformPattern
|
|
89
89
|
exclude?: TransformPattern
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BuiltinPlugin$1 as BuiltinPlugin, InputOptions, RolldownPlugin, buildImportAnalysisPlugin$1 as buildImportAnalysisPlugin, defineParallelPlugin, dynamicImportVarsPlugin$1 as dynamicImportVarsPlugin, importGlobPlugin$1 as importGlobPlugin, isolatedDeclarationPlugin$1 as isolatedDeclarationPlugin, jsonPlugin$1 as jsonPlugin, loadFallbackPlugin$1 as loadFallbackPlugin, manifestPlugin$1 as manifestPlugin, moduleFederationPlugin$1 as moduleFederationPlugin, modulePreloadPolyfillPlugin$1 as modulePreloadPolyfillPlugin, reportPlugin$1 as reportPlugin, viteResolvePlugin$1 as viteResolvePlugin, wasmFallbackPlugin$1 as wasmFallbackPlugin, wasmHelperPlugin$1 as wasmHelperPlugin } from "./shared/input-options.d-
|
|
1
|
+
import { BuiltinPlugin$1 as BuiltinPlugin, InputOptions, RolldownPlugin, buildImportAnalysisPlugin$1 as buildImportAnalysisPlugin, defineParallelPlugin, dynamicImportVarsPlugin$1 as dynamicImportVarsPlugin, importGlobPlugin$1 as importGlobPlugin, isolatedDeclarationPlugin$1 as isolatedDeclarationPlugin, jsonPlugin$1 as jsonPlugin, loadFallbackPlugin$1 as loadFallbackPlugin, manifestPlugin$1 as manifestPlugin, moduleFederationPlugin$1 as moduleFederationPlugin, modulePreloadPolyfillPlugin$1 as modulePreloadPolyfillPlugin, reportPlugin$1 as reportPlugin, viteResolvePlugin$1 as viteResolvePlugin, wasmFallbackPlugin$1 as wasmFallbackPlugin, wasmHelperPlugin$1 as wasmHelperPlugin } from "./shared/input-options.d-BZRlmV0Y.mjs";
|
|
2
2
|
import { BindingReplacePluginConfig, BindingTransformPluginConfig, TransformOptions, TransformResult, moduleRunnerTransform, transform } from "./rolldown-binding.wasi.cjs";
|
|
3
3
|
|
|
4
4
|
//#region src/api/experimental.d.ts
|
|
@@ -83,7 +83,7 @@ declare function replacePlugin(values?: BindingReplacePluginConfig["values"], op
|
|
|
83
83
|
|
|
84
84
|
//#endregion
|
|
85
85
|
//#region src/builtin-plugin/transform-plugin.d.ts
|
|
86
|
-
type TransformPattern = string | RegExp | (RegExp | string)[];
|
|
86
|
+
type TransformPattern = string | RegExp | readonly (RegExp | string)[];
|
|
87
87
|
type TransformPluginConfig = Omit<BindingTransformPluginConfig, "include" | "exclude" | "jsxRefreshInclude" | "jsxRefreshExclude"> & {
|
|
88
88
|
include?: TransformPattern
|
|
89
89
|
exclude?: TransformPattern
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BuiltinPlugin, buildImportAnalysisPlugin, composeJsPlugins, createBundler, dynamicImportVarsPlugin, handleOutputErrors, importGlobPlugin, init_compose_js_plugins, init_constructors, init_create_bundler, init_normalize_string_or_regex, init_transform_to_rollup_output, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, normalizedStringOrRegex, reportPlugin, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin } from "./shared/src-
|
|
2
|
-
import "./shared/parse-ast-index-
|
|
1
|
+
import { BuiltinPlugin, buildImportAnalysisPlugin, composeJsPlugins, createBundler, dynamicImportVarsPlugin, handleOutputErrors, importGlobPlugin, init_compose_js_plugins, init_constructors, init_create_bundler, init_normalize_string_or_regex, init_transform_to_rollup_output, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, normalizedStringOrRegex, reportPlugin, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin } from "./shared/src-Bkj32aeI.mjs";
|
|
2
|
+
import "./shared/parse-ast-index-Cprsj_YY.mjs";
|
|
3
3
|
import { moduleRunnerTransform, transform } from "./rolldown-binding.wasi.cjs";
|
|
4
4
|
import { pathToFileURL } from "node:url";
|
|
5
5
|
|
package/dist/index.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const require_src = require('./shared/src-
|
|
2
|
-
require('./shared/parse-ast-index-
|
|
1
|
+
const require_src = require('./shared/src-BYzJDqvj.cjs');
|
|
2
|
+
require('./shared/parse-ast-index-DAk8Z2V8.cjs');
|
|
3
3
|
|
|
4
4
|
exports.VERSION = require_src.VERSION
|
|
5
5
|
exports.build = require_src.build
|
package/dist/index.d.cts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { AsyncPluginHooks, BuildOptions, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GetModuleInfo, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, JsxOptions, LoadResult, LogLevel, LogOrStringHandler, LoggingFunction, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, PreRenderedChunk, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RollupError, RollupLog, SourceDescription, SourceMap, SourceMapInput, StringFilter, TransformPluginContext, TransformResult, VERSION, WarningHandlerWithDefault, WatchOptions, build, defineConfig, rolldown, watch, withFilter } from "./shared/input-options.d-
|
|
1
|
+
import { AsyncPluginHooks, BuildOptions, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GetModuleInfo, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, JsxOptions, LoadResult, LogLevel, LogOrStringHandler, LoggingFunction, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, PreRenderedChunk, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RollupError, RollupLog, SourceDescription, SourceMap, SourceMapInput, StringFilter, TransformPluginContext, TransformResult, VERSION, WarningHandlerWithDefault, WatchOptions, build, defineConfig, rolldown, watch, withFilter } from "./shared/input-options.d-IUq3nQ6k.cjs";
|
|
2
2
|
|
|
3
3
|
export { AsyncPluginHooks, BuildOptions, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GetModuleInfo, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, JsxOptions, LoadResult, LogLevel, LogOrStringHandler, LoggingFunction, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, PreRenderedChunk, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RollupError, RollupLog, SourceDescription, SourceMap, SourceMapInput, StringFilter, TransformPluginContext, TransformResult, VERSION, WarningHandlerWithDefault, WatchOptions, build, defineConfig, rolldown, watch, withFilter };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { AsyncPluginHooks, BuildOptions, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GetModuleInfo, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, JsxOptions, LoadResult, LogLevel, LogOrStringHandler, LoggingFunction, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, PreRenderedChunk, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RollupError, RollupLog, SourceDescription, SourceMap, SourceMapInput, StringFilter, TransformPluginContext, TransformResult, VERSION$1 as VERSION, WarningHandlerWithDefault, WatchOptions, build$1 as build, defineConfig$1 as defineConfig, rolldown$1 as rolldown, watch$1 as watch, withFilter$1 as withFilter } from "./shared/input-options.d-
|
|
1
|
+
import { AsyncPluginHooks, BuildOptions, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GetModuleInfo, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, JsxOptions, LoadResult, LogLevel, LogOrStringHandler, LoggingFunction, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, PreRenderedChunk, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RollupError, RollupLog, SourceDescription, SourceMap, SourceMapInput, StringFilter, TransformPluginContext, TransformResult, VERSION$1 as VERSION, WarningHandlerWithDefault, WatchOptions, build$1 as build, defineConfig$1 as defineConfig, rolldown$1 as rolldown, watch$1 as watch, withFilter$1 as withFilter } from "./shared/input-options.d-BZRlmV0Y.mjs";
|
|
2
2
|
|
|
3
3
|
export { AsyncPluginHooks, BuildOptions, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GetModuleInfo, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, JsxOptions, LoadResult, LogLevel, LogOrStringHandler, LoggingFunction, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, PreRenderedChunk, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RollupError, RollupLog, SourceDescription, SourceMap, SourceMapInput, StringFilter, TransformPluginContext, TransformResult, VERSION, WarningHandlerWithDefault, WatchOptions, build, defineConfig, rolldown, watch, withFilter };
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { VERSION, build, defineConfig, init_src, rolldown, watch, withFilter } from "./shared/src-
|
|
2
|
-
import "./shared/parse-ast-index-
|
|
1
|
+
import { VERSION, build, defineConfig, init_src, rolldown, watch, withFilter } from "./shared/src-Bkj32aeI.mjs";
|
|
2
|
+
import "./shared/parse-ast-index-Cprsj_YY.mjs";
|
|
3
3
|
|
|
4
4
|
init_src();
|
|
5
5
|
export { VERSION, build, defineConfig, rolldown, watch, withFilter };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const require_chunk = require('./shared/chunk-qZFfknuJ.cjs');
|
|
2
|
-
const require_src = require('./shared/src-
|
|
3
|
-
require('./shared/parse-ast-index-
|
|
2
|
+
const require_src = require('./shared/src-BYzJDqvj.cjs');
|
|
3
|
+
require('./shared/parse-ast-index-DAk8Z2V8.cjs');
|
|
4
4
|
const src_rolldown_binding_wasi_cjs = require_chunk.__toESM(require("./rolldown-binding.wasi.cjs"));
|
|
5
5
|
const node_worker_threads = require_chunk.__toESM(require("node:worker_threads"));
|
|
6
6
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __commonJS } from "./shared/chunk-DSsiIF1Z.mjs";
|
|
2
|
-
import { PluginContextData, bindingifyPlugin, init_bindingify_plugin, init_plugin_context_data } from "./shared/src-
|
|
3
|
-
import "./shared/parse-ast-index-
|
|
2
|
+
import { PluginContextData, bindingifyPlugin, init_bindingify_plugin, init_plugin_context_data } from "./shared/src-Bkj32aeI.mjs";
|
|
3
|
+
import "./shared/parse-ast-index-Cprsj_YY.mjs";
|
|
4
4
|
import { registerPlugins } from "./rolldown-binding.wasi.cjs";
|
|
5
5
|
import { parentPort, workerData } from "node:worker_threads";
|
|
6
6
|
|
package/dist/parse-ast-index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_parse_ast_index = require('./shared/parse-ast-index-
|
|
1
|
+
const require_parse_ast_index = require('./shared/parse-ast-index-DAk8Z2V8.cjs');
|
|
2
2
|
|
|
3
3
|
exports.parseAst = require_parse_ast_index.parseAst
|
|
4
4
|
exports.parseAstAsync = require_parse_ast_index.parseAstAsync
|
package/dist/parse-ast-index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { init_parse_ast_index, parseAst, parseAstAsync } from "./shared/parse-ast-index-
|
|
1
|
+
import { init_parse_ast_index, parseAst, parseAstAsync } from "./shared/parse-ast-index-Cprsj_YY.mjs";
|
|
2
2
|
|
|
3
3
|
init_parse_ast_index();
|
|
4
4
|
export { parseAst, parseAstAsync };
|
|
Binary file
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingViteResolvePluginConfig, BindingWatcherEvent, ParserOptions, PreRenderedChunk, PreRenderedChunk as PreRenderedChunk$1, TransformOptions } from "../rolldown-binding.wasi.cjs";
|
|
1
|
+
import { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingDynamicImportVarsPluginConfig, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingViteResolvePluginConfig, BindingWatcherEvent, ParserOptions, PreRenderedChunk, PreRenderedChunk as PreRenderedChunk$1, TransformOptions } from "../rolldown-binding.wasi.cjs";
|
|
2
2
|
import { Program } from "@oxc-project/types";
|
|
3
3
|
|
|
4
4
|
//#region src/log/logging.d.ts
|
|
@@ -294,6 +294,7 @@ interface OutputOptions {
|
|
|
294
294
|
plugins?: RolldownOutputPluginOption;
|
|
295
295
|
polyfillRequire?: boolean;
|
|
296
296
|
target?: ESTarget;
|
|
297
|
+
hoistTransitiveImports?: false;
|
|
297
298
|
}
|
|
298
299
|
|
|
299
300
|
//#endregion
|
|
@@ -436,12 +437,12 @@ interface HookFilter {
|
|
|
436
437
|
* @example
|
|
437
438
|
* Include all `id`s that contain `node_modules` in the path.
|
|
438
439
|
* ```js
|
|
439
|
-
* { id: 'node_modules' }
|
|
440
|
+
* { id: '**'+'/node_modules/**' }
|
|
440
441
|
* ```
|
|
441
442
|
* @example
|
|
442
443
|
* Include all `id`s that contain `node_modules` or `src` in the path.
|
|
443
444
|
* ```js
|
|
444
|
-
* { id: ['node_modules', 'src'] }
|
|
445
|
+
* { id: ['**'+'/node_modules/**', '**'+'/src/**'] }
|
|
445
446
|
* ```
|
|
446
447
|
* @example
|
|
447
448
|
* Include all `id`s that start with `http`
|
|
@@ -451,14 +452,14 @@ interface HookFilter {
|
|
|
451
452
|
* @example
|
|
452
453
|
* Exclude all `id`s that contain `node_modules` in the path.
|
|
453
454
|
* ```js
|
|
454
|
-
* { id: { exclude: 'node_modules' } }
|
|
455
|
+
* { id: { exclude: '**'+'/node_modules/**' } }
|
|
455
456
|
* ```
|
|
456
457
|
* @example
|
|
457
458
|
* Formal pattern to define includes and excludes.
|
|
458
459
|
* ```
|
|
459
460
|
* { id : {
|
|
460
|
-
* include: [
|
|
461
|
-
* exclude: [
|
|
461
|
+
* include: ['**'+'/foo/**', /bar/],
|
|
462
|
+
* exclude: ['**'+'/baz/**', /qux/]
|
|
462
463
|
* }}
|
|
463
464
|
* ```
|
|
464
465
|
*/
|
|
@@ -615,7 +616,7 @@ declare class BuiltinPlugin {
|
|
|
615
616
|
constructor(name: BindingBuiltinPluginName, _options?: unknown);
|
|
616
617
|
}
|
|
617
618
|
declare function modulePreloadPolyfillPlugin(config?: BindingModulePreloadPolyfillPluginConfig): BuiltinPlugin;
|
|
618
|
-
declare function dynamicImportVarsPlugin(): BuiltinPlugin;
|
|
619
|
+
declare function dynamicImportVarsPlugin(config?: BindingDynamicImportVarsPluginConfig): BuiltinPlugin;
|
|
619
620
|
declare function importGlobPlugin(config?: BindingGlobImportPluginConfig): BuiltinPlugin;
|
|
620
621
|
declare function reportPlugin(config?: BindingReportPluginConfig): BuiltinPlugin;
|
|
621
622
|
declare function manifestPlugin(config?: BindingManifestPluginConfig): BuiltinPlugin;
|
|
@@ -624,7 +625,7 @@ declare function wasmFallbackPlugin(): BuiltinPlugin;
|
|
|
624
625
|
declare function loadFallbackPlugin(): BuiltinPlugin;
|
|
625
626
|
declare function jsonPlugin(config?: BindingJsonPluginConfig): BuiltinPlugin;
|
|
626
627
|
declare function buildImportAnalysisPlugin(config: BindingBuildImportAnalysisPluginConfig): BuiltinPlugin;
|
|
627
|
-
declare function viteResolvePlugin(config:
|
|
628
|
+
declare function viteResolvePlugin(config: BindingViteResolvePluginConfig): BuiltinPlugin;
|
|
628
629
|
type ModuleFederationPluginOption = Omit<BindingModuleFederationPluginOption, "remotes"> & {
|
|
629
630
|
remotes?: Record<string, string | BindingRemote>
|
|
630
631
|
manifest?: boolean | BindingMfManifest
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingViteResolvePluginConfig, BindingWatcherEvent, ParserOptions, PreRenderedChunk, PreRenderedChunk as PreRenderedChunk$1, TransformOptions } from "../rolldown-binding.wasi.cjs";
|
|
1
|
+
import { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingDynamicImportVarsPluginConfig, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingViteResolvePluginConfig, BindingWatcherEvent, ParserOptions, PreRenderedChunk, PreRenderedChunk as PreRenderedChunk$1, TransformOptions } from "../rolldown-binding.wasi.cjs";
|
|
2
2
|
import { Program } from "@oxc-project/types";
|
|
3
3
|
|
|
4
4
|
//#region src/log/logging.d.ts
|
|
@@ -294,6 +294,7 @@ interface OutputOptions {
|
|
|
294
294
|
plugins?: RolldownOutputPluginOption;
|
|
295
295
|
polyfillRequire?: boolean;
|
|
296
296
|
target?: ESTarget;
|
|
297
|
+
hoistTransitiveImports?: false;
|
|
297
298
|
}
|
|
298
299
|
|
|
299
300
|
//#endregion
|
|
@@ -436,12 +437,12 @@ interface HookFilter {
|
|
|
436
437
|
* @example
|
|
437
438
|
* Include all `id`s that contain `node_modules` in the path.
|
|
438
439
|
* ```js
|
|
439
|
-
* { id: 'node_modules' }
|
|
440
|
+
* { id: '**'+'/node_modules/**' }
|
|
440
441
|
* ```
|
|
441
442
|
* @example
|
|
442
443
|
* Include all `id`s that contain `node_modules` or `src` in the path.
|
|
443
444
|
* ```js
|
|
444
|
-
* { id: ['node_modules', 'src'] }
|
|
445
|
+
* { id: ['**'+'/node_modules/**', '**'+'/src/**'] }
|
|
445
446
|
* ```
|
|
446
447
|
* @example
|
|
447
448
|
* Include all `id`s that start with `http`
|
|
@@ -451,14 +452,14 @@ interface HookFilter {
|
|
|
451
452
|
* @example
|
|
452
453
|
* Exclude all `id`s that contain `node_modules` in the path.
|
|
453
454
|
* ```js
|
|
454
|
-
* { id: { exclude: 'node_modules' } }
|
|
455
|
+
* { id: { exclude: '**'+'/node_modules/**' } }
|
|
455
456
|
* ```
|
|
456
457
|
* @example
|
|
457
458
|
* Formal pattern to define includes and excludes.
|
|
458
459
|
* ```
|
|
459
460
|
* { id : {
|
|
460
|
-
* include: [
|
|
461
|
-
* exclude: [
|
|
461
|
+
* include: ['**'+'/foo/**', /bar/],
|
|
462
|
+
* exclude: ['**'+'/baz/**', /qux/]
|
|
462
463
|
* }}
|
|
463
464
|
* ```
|
|
464
465
|
*/
|
|
@@ -615,7 +616,7 @@ declare class BuiltinPlugin {
|
|
|
615
616
|
constructor(name: BindingBuiltinPluginName, _options?: unknown);
|
|
616
617
|
}
|
|
617
618
|
declare function modulePreloadPolyfillPlugin(config?: BindingModulePreloadPolyfillPluginConfig): BuiltinPlugin;
|
|
618
|
-
declare function dynamicImportVarsPlugin(): BuiltinPlugin;
|
|
619
|
+
declare function dynamicImportVarsPlugin(config?: BindingDynamicImportVarsPluginConfig): BuiltinPlugin;
|
|
619
620
|
declare function importGlobPlugin(config?: BindingGlobImportPluginConfig): BuiltinPlugin;
|
|
620
621
|
declare function reportPlugin(config?: BindingReportPluginConfig): BuiltinPlugin;
|
|
621
622
|
declare function manifestPlugin(config?: BindingManifestPluginConfig): BuiltinPlugin;
|
|
@@ -624,7 +625,7 @@ declare function wasmFallbackPlugin(): BuiltinPlugin;
|
|
|
624
625
|
declare function loadFallbackPlugin(): BuiltinPlugin;
|
|
625
626
|
declare function jsonPlugin(config?: BindingJsonPluginConfig): BuiltinPlugin;
|
|
626
627
|
declare function buildImportAnalysisPlugin(config: BindingBuildImportAnalysisPluginConfig): BuiltinPlugin;
|
|
627
|
-
declare function viteResolvePlugin(config:
|
|
628
|
+
declare function viteResolvePlugin(config: BindingViteResolvePluginConfig): BuiltinPlugin;
|
|
628
629
|
type ModuleFederationPluginOption = Omit<BindingModuleFederationPluginOption, "remotes"> & {
|
|
629
630
|
remotes?: Record<string, string | BindingRemote>
|
|
630
631
|
manifest?: boolean | BindingMfManifest
|
|
@@ -137,13 +137,16 @@ function logMultiplyNotifyOption() {
|
|
|
137
137
|
};
|
|
138
138
|
}
|
|
139
139
|
function logPluginError(error$1, plugin, { hook, id } = {}) {
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
140
|
+
try {
|
|
141
|
+
const code = error$1.code;
|
|
142
|
+
if (!error$1.pluginCode && code != null && (typeof code !== "string" || !code.startsWith("PLUGIN_"))) error$1.pluginCode = code;
|
|
143
|
+
error$1.code = PLUGIN_ERROR;
|
|
144
|
+
error$1.plugin = plugin;
|
|
145
|
+
if (hook) error$1.hook = hook;
|
|
146
|
+
if (id) error$1.id = id;
|
|
147
|
+
} catch (_) {} finally {
|
|
148
|
+
return error$1;
|
|
149
|
+
}
|
|
147
150
|
}
|
|
148
151
|
function error(base) {
|
|
149
152
|
if (!(base instanceof Error)) {
|
|
@@ -187,7 +190,7 @@ var init_logs = __esm({ "src/log/logs.ts"() {
|
|
|
187
190
|
} });
|
|
188
191
|
|
|
189
192
|
//#endregion
|
|
190
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
193
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.66.0/node_modules/oxc-parser/wrap.mjs
|
|
191
194
|
function wrap$1(result) {
|
|
192
195
|
let program, module, comments, errors;
|
|
193
196
|
return {
|
|
@@ -223,7 +226,7 @@ function jsonParseAst(ast) {
|
|
|
223
226
|
return value;
|
|
224
227
|
});
|
|
225
228
|
}
|
|
226
|
-
var init_wrap = __esm({ "../../node_modules/.pnpm/oxc-parser@0.
|
|
229
|
+
var init_wrap = __esm({ "../../node_modules/.pnpm/oxc-parser@0.66.0/node_modules/oxc-parser/wrap.mjs"() {} });
|
|
227
230
|
|
|
228
231
|
//#endregion
|
|
229
232
|
//#region src/parse-ast-index.ts
|
|
@@ -135,13 +135,16 @@ function logMultiplyNotifyOption() {
|
|
|
135
135
|
};
|
|
136
136
|
}
|
|
137
137
|
function logPluginError(error$1, plugin, { hook, id } = {}) {
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
138
|
+
try {
|
|
139
|
+
const code = error$1.code;
|
|
140
|
+
if (!error$1.pluginCode && code != null && (typeof code !== "string" || !code.startsWith("PLUGIN_"))) error$1.pluginCode = code;
|
|
141
|
+
error$1.code = PLUGIN_ERROR;
|
|
142
|
+
error$1.plugin = plugin;
|
|
143
|
+
if (hook) error$1.hook = hook;
|
|
144
|
+
if (id) error$1.id = id;
|
|
145
|
+
} catch (_) {} finally {
|
|
146
|
+
return error$1;
|
|
147
|
+
}
|
|
145
148
|
}
|
|
146
149
|
function error(base) {
|
|
147
150
|
if (!(base instanceof Error)) {
|
|
@@ -179,7 +182,7 @@ function augmentCodeLocation(properties, pos, source, id) {
|
|
|
179
182
|
}
|
|
180
183
|
|
|
181
184
|
//#endregion
|
|
182
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
185
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.66.0/node_modules/oxc-parser/wrap.mjs
|
|
183
186
|
function wrap$1(result) {
|
|
184
187
|
let program, module$1, comments, errors;
|
|
185
188
|
return {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const require_chunk = require('./chunk-qZFfknuJ.cjs');
|
|
3
|
-
const require_parse_ast_index = require('./parse-ast-index-
|
|
3
|
+
const require_parse_ast_index = require('./parse-ast-index-DAk8Z2V8.cjs');
|
|
4
4
|
const src_rolldown_binding_wasi_cjs = require_chunk.__toESM(require("../rolldown-binding.wasi.cjs"));
|
|
5
5
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
6
6
|
const __valibot_to_json_schema = require_chunk.__toESM(require("@valibot/to-json-schema"));
|
|
@@ -10,7 +10,7 @@ const node_os = require_chunk.__toESM(require("node:os"));
|
|
|
10
10
|
const node_worker_threads = require_chunk.__toESM(require("node:worker_threads"));
|
|
11
11
|
|
|
12
12
|
//#region package.json
|
|
13
|
-
var version = "1.0.0-beta.8-commit.
|
|
13
|
+
var version = "1.0.0-beta.8-commit.165d0b1";
|
|
14
14
|
var description = "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.";
|
|
15
15
|
|
|
16
16
|
//#endregion
|
|
@@ -41,8 +41,8 @@ var BuiltinPlugin = class {
|
|
|
41
41
|
function modulePreloadPolyfillPlugin(config) {
|
|
42
42
|
return new BuiltinPlugin("builtin:module-preload-polyfill", config);
|
|
43
43
|
}
|
|
44
|
-
function dynamicImportVarsPlugin() {
|
|
45
|
-
return new BuiltinPlugin("builtin:dynamic-import-vars");
|
|
44
|
+
function dynamicImportVarsPlugin(config) {
|
|
45
|
+
return new BuiltinPlugin("builtin:dynamic-import-vars", config);
|
|
46
46
|
}
|
|
47
47
|
function importGlobPlugin(config) {
|
|
48
48
|
return new BuiltinPlugin("builtin:import-glob", config);
|
|
@@ -69,10 +69,7 @@ function buildImportAnalysisPlugin(config) {
|
|
|
69
69
|
return new BuiltinPlugin("builtin:build-import-analysis", config);
|
|
70
70
|
}
|
|
71
71
|
function viteResolvePlugin(config) {
|
|
72
|
-
const builtinPlugin = new BuiltinPlugin("builtin:vite-resolve",
|
|
73
|
-
...config,
|
|
74
|
-
runtime: process.versions.deno ? "deno" : process.versions.bun ? "bun" : "node"
|
|
75
|
-
});
|
|
72
|
+
const builtinPlugin = new BuiltinPlugin("builtin:vite-resolve", config);
|
|
76
73
|
return makeBuiltinPluginCallable(builtinPlugin);
|
|
77
74
|
}
|
|
78
75
|
function moduleFederationPlugin(config) {
|
|
@@ -551,10 +548,9 @@ const ChecksOptionsSchema = valibot.strictObject({
|
|
|
551
548
|
configurationFieldConflict: valibot.pipe(valibot.optional(valibot.boolean()), valibot.description("Whether to emit warning when detecting configuration field conflict"))
|
|
552
549
|
});
|
|
553
550
|
const MinifyOptionsSchema = valibot.strictObject({
|
|
554
|
-
mangle: valibot.boolean(),
|
|
555
|
-
compress: valibot.boolean(),
|
|
556
|
-
|
|
557
|
-
removeWhitespace: valibot.boolean()
|
|
551
|
+
mangle: valibot.optional(valibot.boolean()),
|
|
552
|
+
compress: valibot.optional(valibot.boolean()),
|
|
553
|
+
removeWhitespace: valibot.optional(valibot.boolean())
|
|
558
554
|
});
|
|
559
555
|
const ResolveOptionsSchema = valibot.strictObject({
|
|
560
556
|
alias: valibot.optional(valibot.record(valibot.string(), valibot.union([valibot.string(), valibot.array(valibot.string())]))),
|
|
@@ -737,8 +733,13 @@ const OutputOptionsSchema = valibot.strictObject({
|
|
|
737
733
|
inlineDynamicImports: valibot.pipe(valibot.optional(valibot.boolean()), valibot.description("Inline dynamic imports")),
|
|
738
734
|
advancedChunks: valibot.optional(AdvancedChunksSchema),
|
|
739
735
|
comments: valibot.pipe(valibot.optional(valibot.union([valibot.literal("none"), valibot.literal("preserve-legal")])), valibot.description("Control comments in the output")),
|
|
736
|
+
plugins: valibot.optional(valibot.custom(() => true)),
|
|
737
|
+
polyfillRequire: valibot.pipe(valibot.optional(valibot.boolean()), valibot.description("Disable require polyfill injection")),
|
|
740
738
|
target: valibot.pipe(valibot.optional(valibot.enum(ESTarget)), valibot.description("The JavaScript target environment")),
|
|
741
|
-
|
|
739
|
+
hoistTransitiveImports: valibot.optional(valibot.custom((input) => {
|
|
740
|
+
if (input) return false;
|
|
741
|
+
return true;
|
|
742
|
+
}, () => `The 'true' value is not supported`))
|
|
742
743
|
});
|
|
743
744
|
const getAddonDescription = (placement, wrapper) => {
|
|
744
745
|
return `Code to insert the ${ansis.default.bold(placement)} of the bundled file (${ansis.default.bold(wrapper)} the wrapper function)`;
|
|
@@ -768,7 +769,8 @@ const OutputCliOptionsSchema = valibot.omit(valibot.strictObject({
|
|
|
768
769
|
}), [
|
|
769
770
|
"sourcemapIgnoreList",
|
|
770
771
|
"sourcemapPathTransform",
|
|
771
|
-
"plugins"
|
|
772
|
+
"plugins",
|
|
773
|
+
"hoistTransitiveImports"
|
|
772
774
|
]);
|
|
773
775
|
const CliOptionsSchema = valibot.strictObject({
|
|
774
776
|
config: valibot.pipe(valibot.optional(valibot.union([valibot.string(), valibot.boolean()])), valibot.description("Path to the config file (default: `rolldown.config.js`)")),
|
|
@@ -917,24 +919,6 @@ function joinNewLine(s1, s2) {
|
|
|
917
919
|
return s1.replace(/\n+$/, "") + "\n" + s2.replace(/^\n+/, "");
|
|
918
920
|
}
|
|
919
921
|
|
|
920
|
-
//#endregion
|
|
921
|
-
//#region src/utils/resolved-external.ts
|
|
922
|
-
function transformResolvedExternal(bindingResolvedExternal$1) {
|
|
923
|
-
switch (bindingResolvedExternal$1.type) {
|
|
924
|
-
case "Bool": return bindingResolvedExternal$1.field0;
|
|
925
|
-
case "Absolute": return "absolute";
|
|
926
|
-
case "Relative": unreachable(`The PluginContext resolve result external couldn't be 'relative'`);
|
|
927
|
-
}
|
|
928
|
-
}
|
|
929
|
-
function bindingResolvedExternal(external) {
|
|
930
|
-
if (typeof external === "boolean") return {
|
|
931
|
-
type: "Bool",
|
|
932
|
-
field0: external
|
|
933
|
-
};
|
|
934
|
-
if (external === "absolute") return { type: "Absolute" };
|
|
935
|
-
if (external === "relative") return { type: "Relative" };
|
|
936
|
-
}
|
|
937
|
-
|
|
938
922
|
//#endregion
|
|
939
923
|
//#region src/utils/transform-module-info.ts
|
|
940
924
|
function transformModuleInfo(info, option) {
|
|
@@ -1094,7 +1078,7 @@ var PluginContextImpl = class extends MinimalPluginContextImpl {
|
|
|
1094
1078
|
const info = this.data.getModuleOption(res.id) || {};
|
|
1095
1079
|
return {
|
|
1096
1080
|
...res,
|
|
1097
|
-
external:
|
|
1081
|
+
external: res.external === "relative" ? unreachable(`The PluginContext resolve result external couldn't be 'relative'`) : res.external,
|
|
1098
1082
|
...info
|
|
1099
1083
|
};
|
|
1100
1084
|
}
|
|
@@ -1202,7 +1186,7 @@ function bindingifyResolveId(args) {
|
|
|
1202
1186
|
if (ret == null) return;
|
|
1203
1187
|
if (ret === false) return {
|
|
1204
1188
|
id: specifier,
|
|
1205
|
-
external:
|
|
1189
|
+
external: true,
|
|
1206
1190
|
normalizeExternalId: true
|
|
1207
1191
|
};
|
|
1208
1192
|
if (typeof ret === "string") return {
|
|
@@ -1216,7 +1200,7 @@ function bindingifyResolveId(args) {
|
|
|
1216
1200
|
});
|
|
1217
1201
|
return {
|
|
1218
1202
|
id: ret.id,
|
|
1219
|
-
external:
|
|
1203
|
+
external: ret.external,
|
|
1220
1204
|
normalizeExternalId: false,
|
|
1221
1205
|
sideEffects: bindingifySideEffects(exist.moduleSideEffects)
|
|
1222
1206
|
};
|
|
@@ -1235,12 +1219,12 @@ function bindingifyResolveDynamicImport(args) {
|
|
|
1235
1219
|
if (ret == null) return;
|
|
1236
1220
|
if (ret === false) return {
|
|
1237
1221
|
id: specifier,
|
|
1238
|
-
external:
|
|
1222
|
+
external: true
|
|
1239
1223
|
};
|
|
1240
1224
|
if (typeof ret === "string") return { id: ret };
|
|
1241
1225
|
const result = {
|
|
1242
1226
|
id: ret.id,
|
|
1243
|
-
external:
|
|
1227
|
+
external: ret.external
|
|
1244
1228
|
};
|
|
1245
1229
|
if (ret.moduleSideEffects !== null) result.sideEffects = bindingifySideEffects(ret.moduleSideEffects);
|
|
1246
1230
|
args.pluginContextData.updateModuleOption(ret.id, {
|
|
@@ -2158,9 +2142,12 @@ var PluginContextData = class {
|
|
|
2158
2142
|
//#region src/utils/normalize-string-or-regex.ts
|
|
2159
2143
|
function normalizedStringOrRegex(pattern) {
|
|
2160
2144
|
if (!pattern) return void 0;
|
|
2161
|
-
if (!
|
|
2145
|
+
if (!isReadonlyArray(pattern)) return [pattern];
|
|
2162
2146
|
return pattern;
|
|
2163
2147
|
}
|
|
2148
|
+
function isReadonlyArray(input) {
|
|
2149
|
+
return Array.isArray(input);
|
|
2150
|
+
}
|
|
2164
2151
|
|
|
2165
2152
|
//#endregion
|
|
2166
2153
|
//#region src/utils/bindingify-input-options.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __esm } from "./chunk-DSsiIF1Z.mjs";
|
|
2
|
-
import { augmentCodeLocation, error, init_logs, init_parse_ast_index, logCycleLoading, logInputHookInOutputPlugin, logInvalidLogPosition, logMultiplyNotifyOption, logPluginError, parseAst } from "./parse-ast-index-
|
|
2
|
+
import { augmentCodeLocation, error, init_logs, init_parse_ast_index, logCycleLoading, logInputHookInOutputPlugin, logInvalidLogPosition, logMultiplyNotifyOption, logPluginError, parseAst } from "./parse-ast-index-Cprsj_YY.mjs";
|
|
3
3
|
import { BindingCallableBuiltinPlugin, BindingHookSideEffects, BindingLogLevel, BindingPluginOrder, BindingWatcher, Bundler, ParallelJsPluginRegistry, shutdownAsyncRuntime, startAsyncRuntime } from "../rolldown-binding.wasi.cjs";
|
|
4
4
|
import path from "node:path";
|
|
5
5
|
import { toJsonSchema } from "@valibot/to-json-schema";
|
|
@@ -9,7 +9,7 @@ import { availableParallelism } from "node:os";
|
|
|
9
9
|
import { Worker } from "node:worker_threads";
|
|
10
10
|
|
|
11
11
|
//#region package.json
|
|
12
|
-
var version = "1.0.0-beta.8-commit.
|
|
12
|
+
var version = "1.0.0-beta.8-commit.165d0b1";
|
|
13
13
|
var description = "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.";
|
|
14
14
|
|
|
15
15
|
//#endregion
|
|
@@ -35,8 +35,8 @@ var init_utils = __esm({ "src/builtin-plugin/utils.ts"() {} });
|
|
|
35
35
|
function modulePreloadPolyfillPlugin(config) {
|
|
36
36
|
return new BuiltinPlugin("builtin:module-preload-polyfill", config);
|
|
37
37
|
}
|
|
38
|
-
function dynamicImportVarsPlugin() {
|
|
39
|
-
return new BuiltinPlugin("builtin:dynamic-import-vars");
|
|
38
|
+
function dynamicImportVarsPlugin(config) {
|
|
39
|
+
return new BuiltinPlugin("builtin:dynamic-import-vars", config);
|
|
40
40
|
}
|
|
41
41
|
function importGlobPlugin(config) {
|
|
42
42
|
return new BuiltinPlugin("builtin:import-glob", config);
|
|
@@ -63,10 +63,7 @@ function buildImportAnalysisPlugin(config) {
|
|
|
63
63
|
return new BuiltinPlugin("builtin:build-import-analysis", config);
|
|
64
64
|
}
|
|
65
65
|
function viteResolvePlugin(config) {
|
|
66
|
-
const builtinPlugin = new BuiltinPlugin("builtin:vite-resolve",
|
|
67
|
-
...config,
|
|
68
|
-
runtime: process.versions.deno ? "deno" : process.versions.bun ? "bun" : "node"
|
|
69
|
-
});
|
|
66
|
+
const builtinPlugin = new BuiltinPlugin("builtin:vite-resolve", config);
|
|
70
67
|
return makeBuiltinPluginCallable(builtinPlugin);
|
|
71
68
|
}
|
|
72
69
|
function moduleFederationPlugin(config) {
|
|
@@ -634,10 +631,9 @@ var init_validator = __esm({ "src/utils/validator.ts"() {
|
|
|
634
631
|
configurationFieldConflict: v.pipe(v.optional(v.boolean()), v.description("Whether to emit warning when detecting configuration field conflict"))
|
|
635
632
|
});
|
|
636
633
|
MinifyOptionsSchema = v.strictObject({
|
|
637
|
-
mangle: v.boolean(),
|
|
638
|
-
compress: v.boolean(),
|
|
639
|
-
|
|
640
|
-
removeWhitespace: v.boolean()
|
|
634
|
+
mangle: v.optional(v.boolean()),
|
|
635
|
+
compress: v.optional(v.boolean()),
|
|
636
|
+
removeWhitespace: v.optional(v.boolean())
|
|
641
637
|
});
|
|
642
638
|
ResolveOptionsSchema = v.strictObject({
|
|
643
639
|
alias: v.optional(v.record(v.string(), v.union([v.string(), v.array(v.string())]))),
|
|
@@ -820,8 +816,13 @@ var init_validator = __esm({ "src/utils/validator.ts"() {
|
|
|
820
816
|
inlineDynamicImports: v.pipe(v.optional(v.boolean()), v.description("Inline dynamic imports")),
|
|
821
817
|
advancedChunks: v.optional(AdvancedChunksSchema),
|
|
822
818
|
comments: v.pipe(v.optional(v.union([v.literal("none"), v.literal("preserve-legal")])), v.description("Control comments in the output")),
|
|
819
|
+
plugins: v.optional(v.custom(() => true)),
|
|
820
|
+
polyfillRequire: v.pipe(v.optional(v.boolean()), v.description("Disable require polyfill injection")),
|
|
823
821
|
target: v.pipe(v.optional(v.enum(ESTarget)), v.description("The JavaScript target environment")),
|
|
824
|
-
|
|
822
|
+
hoistTransitiveImports: v.optional(v.custom((input) => {
|
|
823
|
+
if (input) return false;
|
|
824
|
+
return true;
|
|
825
|
+
}, () => `The 'true' value is not supported`))
|
|
825
826
|
});
|
|
826
827
|
getAddonDescription = (placement, wrapper) => {
|
|
827
828
|
return `Code to insert the ${colors.bold(placement)} of the bundled file (${colors.bold(wrapper)} the wrapper function)`;
|
|
@@ -851,7 +852,8 @@ var init_validator = __esm({ "src/utils/validator.ts"() {
|
|
|
851
852
|
}), [
|
|
852
853
|
"sourcemapIgnoreList",
|
|
853
854
|
"sourcemapPathTransform",
|
|
854
|
-
"plugins"
|
|
855
|
+
"plugins",
|
|
856
|
+
"hoistTransitiveImports"
|
|
855
857
|
]);
|
|
856
858
|
CliOptionsSchema = v.strictObject({
|
|
857
859
|
config: v.pipe(v.optional(v.union([v.string(), v.boolean()])), v.description("Path to the config file (default: `rolldown.config.js`)")),
|
|
@@ -965,27 +967,6 @@ function joinNewLine(s1, s2) {
|
|
|
965
967
|
}
|
|
966
968
|
var init_error = __esm({ "src/utils/error.ts"() {} });
|
|
967
969
|
|
|
968
|
-
//#endregion
|
|
969
|
-
//#region src/utils/resolved-external.ts
|
|
970
|
-
function transformResolvedExternal(bindingResolvedExternal$1) {
|
|
971
|
-
switch (bindingResolvedExternal$1.type) {
|
|
972
|
-
case "Bool": return bindingResolvedExternal$1.field0;
|
|
973
|
-
case "Absolute": return "absolute";
|
|
974
|
-
case "Relative": unreachable(`The PluginContext resolve result external couldn't be 'relative'`);
|
|
975
|
-
}
|
|
976
|
-
}
|
|
977
|
-
function bindingResolvedExternal(external) {
|
|
978
|
-
if (typeof external === "boolean") return {
|
|
979
|
-
type: "Bool",
|
|
980
|
-
field0: external
|
|
981
|
-
};
|
|
982
|
-
if (external === "absolute") return { type: "Absolute" };
|
|
983
|
-
if (external === "relative") return { type: "Relative" };
|
|
984
|
-
}
|
|
985
|
-
var init_resolved_external = __esm({ "src/utils/resolved-external.ts"() {
|
|
986
|
-
init_misc();
|
|
987
|
-
} });
|
|
988
|
-
|
|
989
970
|
//#endregion
|
|
990
971
|
//#region src/utils/transform-module-info.ts
|
|
991
972
|
function transformModuleInfo(info, option) {
|
|
@@ -1108,7 +1089,6 @@ var init_plugin_context = __esm({ "src/plugin/plugin-context.ts"() {
|
|
|
1108
1089
|
init_minimal_plugin_context();
|
|
1109
1090
|
init_asset_source();
|
|
1110
1091
|
init_misc();
|
|
1111
|
-
init_resolved_external();
|
|
1112
1092
|
init_transform_side_effects();
|
|
1113
1093
|
PluginContextImpl = class extends MinimalPluginContextImpl {
|
|
1114
1094
|
getModuleInfo;
|
|
@@ -1165,7 +1145,7 @@ var init_plugin_context = __esm({ "src/plugin/plugin-context.ts"() {
|
|
|
1165
1145
|
const info = this.data.getModuleOption(res.id) || {};
|
|
1166
1146
|
return {
|
|
1167
1147
|
...res,
|
|
1168
|
-
external:
|
|
1148
|
+
external: res.external === "relative" ? unreachable(`The PluginContext resolve result external couldn't be 'relative'`) : res.external,
|
|
1169
1149
|
...info
|
|
1170
1150
|
};
|
|
1171
1151
|
}
|
|
@@ -1280,7 +1260,7 @@ function bindingifyResolveId(args) {
|
|
|
1280
1260
|
if (ret == null) return;
|
|
1281
1261
|
if (ret === false) return {
|
|
1282
1262
|
id: specifier,
|
|
1283
|
-
external:
|
|
1263
|
+
external: true,
|
|
1284
1264
|
normalizeExternalId: true
|
|
1285
1265
|
};
|
|
1286
1266
|
if (typeof ret === "string") return {
|
|
@@ -1294,7 +1274,7 @@ function bindingifyResolveId(args) {
|
|
|
1294
1274
|
});
|
|
1295
1275
|
return {
|
|
1296
1276
|
id: ret.id,
|
|
1297
|
-
external:
|
|
1277
|
+
external: ret.external,
|
|
1298
1278
|
normalizeExternalId: false,
|
|
1299
1279
|
sideEffects: bindingifySideEffects(exist.moduleSideEffects)
|
|
1300
1280
|
};
|
|
@@ -1313,12 +1293,12 @@ function bindingifyResolveDynamicImport(args) {
|
|
|
1313
1293
|
if (ret == null) return;
|
|
1314
1294
|
if (ret === false) return {
|
|
1315
1295
|
id: specifier,
|
|
1316
|
-
external:
|
|
1296
|
+
external: true
|
|
1317
1297
|
};
|
|
1318
1298
|
if (typeof ret === "string") return { id: ret };
|
|
1319
1299
|
const result = {
|
|
1320
1300
|
id: ret.id,
|
|
1321
|
-
external:
|
|
1301
|
+
external: ret.external
|
|
1322
1302
|
};
|
|
1323
1303
|
if (ret.moduleSideEffects !== null) result.sideEffects = bindingifySideEffects(ret.moduleSideEffects);
|
|
1324
1304
|
args.pluginContextData.updateModuleOption(ret.id, {
|
|
@@ -1409,7 +1389,6 @@ var init_bindingify_build_hooks = __esm({ "src/plugin/bindingify-build-hooks.ts"
|
|
|
1409
1389
|
init_normalized_input_options();
|
|
1410
1390
|
init_sourcemap();
|
|
1411
1391
|
init_error();
|
|
1412
|
-
init_resolved_external();
|
|
1413
1392
|
init_transform_module_info();
|
|
1414
1393
|
init_transform_side_effects();
|
|
1415
1394
|
init_transform_sourcemap();
|
|
@@ -2300,9 +2279,12 @@ var init_plugin_context_data = __esm({ "src/plugin/plugin-context-data.ts"() {
|
|
|
2300
2279
|
//#region src/utils/normalize-string-or-regex.ts
|
|
2301
2280
|
function normalizedStringOrRegex(pattern) {
|
|
2302
2281
|
if (!pattern) return void 0;
|
|
2303
|
-
if (!
|
|
2282
|
+
if (!isReadonlyArray(pattern)) return [pattern];
|
|
2304
2283
|
return pattern;
|
|
2305
2284
|
}
|
|
2285
|
+
function isReadonlyArray(input) {
|
|
2286
|
+
return Array.isArray(input);
|
|
2287
|
+
}
|
|
2306
2288
|
var init_normalize_string_or_regex = __esm({ "src/utils/normalize-string-or-regex.ts"() {} });
|
|
2307
2289
|
|
|
2308
2290
|
//#endregion
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rolldown/browser",
|
|
3
|
-
"version": "1.0.0-beta.8-commit.
|
|
3
|
+
"version": "1.0.0-beta.8-commit.165d0b1",
|
|
4
4
|
"description": "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.",
|
|
5
5
|
"homepage": "https://rolldown.rs/",
|
|
6
6
|
"type": "module",
|
|
@@ -55,14 +55,14 @@
|
|
|
55
55
|
},
|
|
56
56
|
"dependencies": {
|
|
57
57
|
"@napi-rs/wasm-runtime": "^0.2.8",
|
|
58
|
-
"@oxc-project/types": "0.
|
|
58
|
+
"@oxc-project/types": "0.66.0",
|
|
59
59
|
"@valibot/to-json-schema": "1.0.0",
|
|
60
60
|
"ansis": "^3.17.0",
|
|
61
61
|
"pathe": "^2.0.3",
|
|
62
62
|
"valibot": "1.0.0"
|
|
63
63
|
},
|
|
64
64
|
"peerDependencies": {
|
|
65
|
-
"@oxc-project/runtime": "0.
|
|
65
|
+
"@oxc-project/runtime": "0.66.0"
|
|
66
66
|
},
|
|
67
67
|
"peerDependenciesMeta": {
|
|
68
68
|
"@oxc-project/runtime": {
|