rolldown 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/cli.cjs +8 -6
- package/dist/cli.mjs +8 -6
- package/dist/experimental-index.cjs +2 -2
- package/dist/experimental-index.d.cts +3 -3
- package/dist/experimental-index.d.mts +3 -3
- package/dist/experimental-index.mjs +2 -2
- package/dist/index.cjs +2 -2
- package/dist/index.d.cts +2 -2
- package/dist/index.d.mts +2 -2
- 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 +2 -2
- package/dist/parallel-plugin.d.mts +2 -2
- package/dist/parse-ast-index.cjs +1 -1
- package/dist/parse-ast-index.d.cts +1 -1
- package/dist/parse-ast-index.d.mts +1 -1
- package/dist/parse-ast-index.mjs +1 -1
- package/dist/shared/{binding.d-BByJLDH2.d.mts → binding.d-B05CM1o6.d.cts} +9 -5
- package/dist/shared/{binding.d-BsXYWSiO.d.cts → binding.d-hdeVvoYV.d.mts} +9 -5
- package/dist/shared/{input-options.d-C0k6AcBU.d.cts → input-options.d-B7FcCgHX.d.cts} +9 -8
- package/dist/shared/{input-options.d-DUUrYkQA.d.mts → input-options.d-D0Veb39u.d.mts} +9 -8
- package/dist/shared/{parse-ast-index-83yhN6Wa.mjs → parse-ast-index-CJTgEIMh.mjs} +12 -9
- package/dist/shared/{parse-ast-index-Dfo0zI2n.cjs → parse-ast-index-DROW_mqO.cjs} +11 -8
- package/dist/shared/{src-DFYE-Esq.mjs → src-CAE2SwAw.mjs} +25 -43
- package/dist/shared/{src-kfoEIeOg.cjs → src-CpuvViAc.cjs} +25 -38
- package/package.json +17 -17
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-CpuvViAc.cjs');
|
|
3
|
+
require('./shared/parse-ast-index-DROW_mqO.cjs');
|
|
4
4
|
const node_fs = require_chunk.__toESM(require("node:fs"));
|
|
5
5
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
6
6
|
const ansis = require_chunk.__toESM(require("ansis"));
|
|
@@ -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-DUYDk_2O.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-CAE2SwAw.mjs";
|
|
3
|
+
import "./shared/parse-ast-index-CJTgEIMh.mjs";
|
|
4
4
|
import fs from "node:fs";
|
|
5
5
|
import path, { sep } from "node:path";
|
|
6
6
|
import colors from "ansis";
|
|
@@ -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
|
-
const require_parse_ast_index = require('./shared/parse-ast-index-
|
|
3
|
+
const require_src = require('./shared/src-CpuvViAc.cjs');
|
|
4
|
+
const require_parse_ast_index = require('./shared/parse-ast-index-DROW_mqO.cjs');
|
|
5
5
|
const node_url = require_chunk.__toESM(require("node:url"));
|
|
6
6
|
|
|
7
7
|
//#region src/api/experimental.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BindingReplacePluginConfig, BindingTransformPluginConfig, TransformOptions, TransformResult$1 as TransformResult, moduleRunnerTransform, transform } from "./shared/binding.d-
|
|
2
|
-
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 { BindingReplacePluginConfig, BindingTransformPluginConfig, TransformOptions, TransformResult$1 as TransformResult, moduleRunnerTransform, transform } from "./shared/binding.d-B05CM1o6.cjs";
|
|
2
|
+
import { BuiltinPlugin, InputOptions, RolldownPlugin, buildImportAnalysisPlugin, defineParallelPlugin, dynamicImportVarsPlugin, importGlobPlugin, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, reportPlugin, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin } from "./shared/input-options.d-B7FcCgHX.cjs";
|
|
3
3
|
|
|
4
4
|
//#region src/api/experimental.d.ts
|
|
5
5
|
/**
|
|
@@ -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 { BindingReplacePluginConfig, BindingTransformPluginConfig, TransformOptions, TransformResult$1 as TransformResult, moduleRunnerTransform, transform } from "./shared/binding.d-
|
|
2
|
-
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 { BindingReplacePluginConfig, BindingTransformPluginConfig, TransformOptions, TransformResult$1 as TransformResult, moduleRunnerTransform, transform } from "./shared/binding.d-hdeVvoYV.mjs";
|
|
2
|
+
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-D0Veb39u.mjs";
|
|
3
3
|
|
|
4
4
|
//#region src/api/experimental.d.ts
|
|
5
5
|
/**
|
|
@@ -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 { import_binding } from "./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-CAE2SwAw.mjs";
|
|
2
|
+
import { import_binding } from "./shared/parse-ast-index-CJTgEIMh.mjs";
|
|
3
3
|
import { pathToFileURL } from "node:url";
|
|
4
4
|
|
|
5
5
|
//#region src/api/experimental.ts
|
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-CpuvViAc.cjs');
|
|
2
|
+
require('./shared/parse-ast-index-DROW_mqO.cjs');
|
|
3
3
|
|
|
4
4
|
exports.VERSION = require_src.VERSION
|
|
5
5
|
exports.build = require_src.build
|
package/dist/index.d.cts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PreRenderedChunk } from "./shared/binding.d-
|
|
2
|
-
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, 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 { PreRenderedChunk } from "./shared/binding.d-B05CM1o6.cjs";
|
|
2
|
+
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, 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-B7FcCgHX.cjs";
|
|
3
3
|
|
|
4
4
|
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,4 +1,4 @@
|
|
|
1
|
-
import { PreRenderedChunk } from "./shared/binding.d-
|
|
2
|
-
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, 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 { PreRenderedChunk } from "./shared/binding.d-hdeVvoYV.mjs";
|
|
2
|
+
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, 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-D0Veb39u.mjs";
|
|
3
3
|
|
|
4
4
|
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-CAE2SwAw.mjs";
|
|
2
|
+
import "./shared/parse-ast-index-CJTgEIMh.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
|
-
const require_parse_ast_index = require('./shared/parse-ast-index-
|
|
2
|
+
const require_src = require('./shared/src-CpuvViAc.cjs');
|
|
3
|
+
const require_parse_ast_index = require('./shared/parse-ast-index-DROW_mqO.cjs');
|
|
4
4
|
const node_worker_threads = require_chunk.__toESM(require("node:worker_threads"));
|
|
5
5
|
|
|
6
6
|
//#region src/parallel-plugin-worker.ts
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __commonJS } from "./shared/chunk-DUYDk_2O.mjs";
|
|
2
|
-
import { PluginContextData, bindingifyPlugin, init_bindingify_plugin, init_plugin_context_data } from "./shared/src-
|
|
3
|
-
import { import_binding } from "./shared/parse-ast-index-
|
|
2
|
+
import { PluginContextData, bindingifyPlugin, init_bindingify_plugin, init_plugin_context_data } from "./shared/src-CAE2SwAw.mjs";
|
|
3
|
+
import { import_binding } from "./shared/parse-ast-index-CJTgEIMh.mjs";
|
|
4
4
|
import { parentPort, workerData } from "node:worker_threads";
|
|
5
5
|
|
|
6
6
|
//#region src/parallel-plugin-worker.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "./shared/binding.d-
|
|
2
|
-
import { MaybePromise, Plugin } from "./shared/input-options.d-
|
|
1
|
+
import "./shared/binding.d-B05CM1o6.cjs";
|
|
2
|
+
import { MaybePromise, Plugin } from "./shared/input-options.d-B7FcCgHX.cjs";
|
|
3
3
|
|
|
4
4
|
//#region src/plugin/parallel-plugin-implementation.d.ts
|
|
5
5
|
type ParallelPluginImplementation = Plugin;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "./shared/binding.d-
|
|
2
|
-
import { MaybePromise, Plugin } from "./shared/input-options.d-
|
|
1
|
+
import "./shared/binding.d-hdeVvoYV.mjs";
|
|
2
|
+
import { MaybePromise, Plugin } from "./shared/input-options.d-D0Veb39u.mjs";
|
|
3
3
|
|
|
4
4
|
//#region src/plugin/parallel-plugin-implementation.d.ts
|
|
5
5
|
type ParallelPluginImplementation = Plugin;
|
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-DROW_mqO.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-CJTgEIMh.mjs";
|
|
2
2
|
|
|
3
3
|
init_parse_ast_index();
|
|
4
4
|
export { parseAst, parseAstAsync };
|
|
@@ -67,6 +67,10 @@ type BindingBuiltinPluginName = 'builtin:wasm-helper'|
|
|
|
67
67
|
'builtin:module-federation'|
|
|
68
68
|
'builtin:isolated-declaration'|
|
|
69
69
|
'builtin:report';
|
|
70
|
+
interface BindingDynamicImportVarsPluginConfig {
|
|
71
|
+
include?: Array<BindingStringOrRegex>
|
|
72
|
+
exclude?: Array<BindingStringOrRegex>
|
|
73
|
+
}
|
|
70
74
|
interface BindingGlobImportPluginConfig {
|
|
71
75
|
root?: string
|
|
72
76
|
restoreQueryExtension?: boolean
|
|
@@ -105,9 +109,9 @@ interface BindingMfManifest {
|
|
|
105
109
|
fileName?: string
|
|
106
110
|
}
|
|
107
111
|
interface BindingMinifyOptions {
|
|
108
|
-
mangle
|
|
109
|
-
compress
|
|
110
|
-
removeWhitespace
|
|
112
|
+
mangle?: boolean
|
|
113
|
+
compress?: boolean
|
|
114
|
+
removeWhitespace?: boolean
|
|
111
115
|
}
|
|
112
116
|
interface BindingModuleFederationPluginOption {
|
|
113
117
|
name: string
|
|
@@ -167,12 +171,12 @@ interface BindingViteResolvePluginConfig {
|
|
|
167
171
|
resolveOptions: BindingViteResolvePluginResolveOptions
|
|
168
172
|
environmentConsumer: string
|
|
169
173
|
environmentName: string
|
|
174
|
+
builtins: Array<BindingStringOrRegex>
|
|
170
175
|
external: true | string[]
|
|
171
176
|
noExternal: true | Array<string | RegExp>
|
|
172
177
|
dedupe: Array<string>
|
|
173
178
|
finalizeBareSpecifier?: (resolvedId: string, rawId: string, importer: string | null | undefined) => VoidNullable<string>
|
|
174
179
|
finalizeOtherSpecifiers?: (resolvedId: string, rawId: string) => VoidNullable<string>
|
|
175
|
-
runtime: string
|
|
176
180
|
}
|
|
177
181
|
interface BindingViteResolvePluginResolveOptions {
|
|
178
182
|
isBuild: boolean
|
|
@@ -836,4 +840,4 @@ interface ValueSpan {
|
|
|
836
840
|
}
|
|
837
841
|
|
|
838
842
|
//#endregion
|
|
839
|
-
export { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReplacePluginConfig, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingTransformPluginConfig, BindingViteResolvePluginConfig, BindingWatcherEvent, ParseResult, ParserOptions, PreRenderedChunk, TransformOptions, TransformResult as TransformResult$1, moduleRunnerTransform, transform };
|
|
843
|
+
export { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingDynamicImportVarsPluginConfig, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReplacePluginConfig, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingTransformPluginConfig, BindingViteResolvePluginConfig, BindingWatcherEvent, ParseResult, ParserOptions, PreRenderedChunk, TransformOptions, TransformResult as TransformResult$1, moduleRunnerTransform, transform };
|
|
@@ -67,6 +67,10 @@ type BindingBuiltinPluginName = 'builtin:wasm-helper'|
|
|
|
67
67
|
'builtin:module-federation'|
|
|
68
68
|
'builtin:isolated-declaration'|
|
|
69
69
|
'builtin:report';
|
|
70
|
+
interface BindingDynamicImportVarsPluginConfig {
|
|
71
|
+
include?: Array<BindingStringOrRegex>
|
|
72
|
+
exclude?: Array<BindingStringOrRegex>
|
|
73
|
+
}
|
|
70
74
|
interface BindingGlobImportPluginConfig {
|
|
71
75
|
root?: string
|
|
72
76
|
restoreQueryExtension?: boolean
|
|
@@ -105,9 +109,9 @@ interface BindingMfManifest {
|
|
|
105
109
|
fileName?: string
|
|
106
110
|
}
|
|
107
111
|
interface BindingMinifyOptions {
|
|
108
|
-
mangle
|
|
109
|
-
compress
|
|
110
|
-
removeWhitespace
|
|
112
|
+
mangle?: boolean
|
|
113
|
+
compress?: boolean
|
|
114
|
+
removeWhitespace?: boolean
|
|
111
115
|
}
|
|
112
116
|
interface BindingModuleFederationPluginOption {
|
|
113
117
|
name: string
|
|
@@ -167,12 +171,12 @@ interface BindingViteResolvePluginConfig {
|
|
|
167
171
|
resolveOptions: BindingViteResolvePluginResolveOptions
|
|
168
172
|
environmentConsumer: string
|
|
169
173
|
environmentName: string
|
|
174
|
+
builtins: Array<BindingStringOrRegex>
|
|
170
175
|
external: true | string[]
|
|
171
176
|
noExternal: true | Array<string | RegExp>
|
|
172
177
|
dedupe: Array<string>
|
|
173
178
|
finalizeBareSpecifier?: (resolvedId: string, rawId: string, importer: string | null | undefined) => VoidNullable<string>
|
|
174
179
|
finalizeOtherSpecifiers?: (resolvedId: string, rawId: string) => VoidNullable<string>
|
|
175
|
-
runtime: string
|
|
176
180
|
}
|
|
177
181
|
interface BindingViteResolvePluginResolveOptions {
|
|
178
182
|
isBuild: boolean
|
|
@@ -836,4 +840,4 @@ interface ValueSpan {
|
|
|
836
840
|
}
|
|
837
841
|
|
|
838
842
|
//#endregion
|
|
839
|
-
export { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReplacePluginConfig, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingTransformPluginConfig, BindingViteResolvePluginConfig, BindingWatcherEvent, ParseResult, ParserOptions, PreRenderedChunk, TransformOptions, TransformResult as TransformResult$1, moduleRunnerTransform, transform };
|
|
843
|
+
export { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingDynamicImportVarsPluginConfig, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReplacePluginConfig, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingTransformPluginConfig, BindingViteResolvePluginConfig, BindingWatcherEvent, ParseResult, ParserOptions, PreRenderedChunk, TransformOptions, TransformResult as TransformResult$1, moduleRunnerTransform, transform };
|
|
@@ -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, TransformOptions } from "./binding.d-
|
|
1
|
+
import { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingDynamicImportVarsPluginConfig, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingViteResolvePluginConfig, BindingWatcherEvent, ParserOptions, PreRenderedChunk, TransformOptions } from "./binding.d-B05CM1o6.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, TransformOptions } from "./binding.d-
|
|
1
|
+
import { BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingDynamicImportVarsPluginConfig, BindingGlobImportPluginConfig, BindingHmrOutput, BindingHookResolveIdExtraArgs, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReportPluginConfig, BindingTransformHookExtraArgs, BindingViteResolvePluginConfig, BindingWatcherEvent, ParserOptions, PreRenderedChunk, TransformOptions } from "./binding.d-hdeVvoYV.mjs";
|
|
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
|
|
@@ -507,13 +507,16 @@ function logMultiplyNotifyOption() {
|
|
|
507
507
|
};
|
|
508
508
|
}
|
|
509
509
|
function logPluginError(error$1, plugin, { hook, id } = {}) {
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
510
|
+
try {
|
|
511
|
+
const code = error$1.code;
|
|
512
|
+
if (!error$1.pluginCode && code != null && (typeof code !== "string" || !code.startsWith("PLUGIN_"))) error$1.pluginCode = code;
|
|
513
|
+
error$1.code = PLUGIN_ERROR;
|
|
514
|
+
error$1.plugin = plugin;
|
|
515
|
+
if (hook) error$1.hook = hook;
|
|
516
|
+
if (id) error$1.id = id;
|
|
517
|
+
} catch (_) {} finally {
|
|
518
|
+
return error$1;
|
|
519
|
+
}
|
|
517
520
|
}
|
|
518
521
|
function error(base) {
|
|
519
522
|
if (!(base instanceof Error)) {
|
|
@@ -557,7 +560,7 @@ var init_logs = __esm({ "src/log/logs.ts"() {
|
|
|
557
560
|
} });
|
|
558
561
|
|
|
559
562
|
//#endregion
|
|
560
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
563
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.66.0/node_modules/oxc-parser/wrap.mjs
|
|
561
564
|
function wrap$1(result) {
|
|
562
565
|
let program, module$1, comments, errors;
|
|
563
566
|
return {
|
|
@@ -593,7 +596,7 @@ function jsonParseAst(ast) {
|
|
|
593
596
|
return value;
|
|
594
597
|
});
|
|
595
598
|
}
|
|
596
|
-
var init_wrap = __esm({ "../../node_modules/.pnpm/oxc-parser@0.
|
|
599
|
+
var init_wrap = __esm({ "../../node_modules/.pnpm/oxc-parser@0.66.0/node_modules/oxc-parser/wrap.mjs"() {} });
|
|
597
600
|
|
|
598
601
|
//#endregion
|
|
599
602
|
//#region src/parse-ast-index.ts
|
|
@@ -504,13 +504,16 @@ function logMultiplyNotifyOption() {
|
|
|
504
504
|
};
|
|
505
505
|
}
|
|
506
506
|
function logPluginError(error$1, plugin, { hook, id } = {}) {
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
507
|
+
try {
|
|
508
|
+
const code = error$1.code;
|
|
509
|
+
if (!error$1.pluginCode && code != null && (typeof code !== "string" || !code.startsWith("PLUGIN_"))) error$1.pluginCode = code;
|
|
510
|
+
error$1.code = PLUGIN_ERROR;
|
|
511
|
+
error$1.plugin = plugin;
|
|
512
|
+
if (hook) error$1.hook = hook;
|
|
513
|
+
if (id) error$1.id = id;
|
|
514
|
+
} catch (_) {} finally {
|
|
515
|
+
return error$1;
|
|
516
|
+
}
|
|
514
517
|
}
|
|
515
518
|
function error(base) {
|
|
516
519
|
if (!(base instanceof Error)) {
|
|
@@ -548,7 +551,7 @@ function augmentCodeLocation(properties, pos, source, id) {
|
|
|
548
551
|
}
|
|
549
552
|
|
|
550
553
|
//#endregion
|
|
551
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
554
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.66.0/node_modules/oxc-parser/wrap.mjs
|
|
552
555
|
function wrap$1(result) {
|
|
553
556
|
let program, module$1, comments, errors;
|
|
554
557
|
return {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __esm } from "./chunk-DUYDk_2O.mjs";
|
|
2
|
-
import { augmentCodeLocation, error, import_binding, init_logs, init_parse_ast_index, logCycleLoading, logInputHookInOutputPlugin, logInvalidLogPosition, logMultiplyNotifyOption, logPluginError, parseAst } from "./parse-ast-index-
|
|
2
|
+
import { augmentCodeLocation, error, import_binding, init_logs, init_parse_ast_index, logCycleLoading, logInputHookInOutputPlugin, logInvalidLogPosition, logMultiplyNotifyOption, logPluginError, parseAst } from "./parse-ast-index-CJTgEIMh.mjs";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import { toJsonSchema } from "@valibot/to-json-schema";
|
|
5
5
|
import colors from "ansis";
|
|
@@ -8,7 +8,7 @@ import { availableParallelism } from "node:os";
|
|
|
8
8
|
import { Worker } from "node:worker_threads";
|
|
9
9
|
|
|
10
10
|
//#region package.json
|
|
11
|
-
var version = "1.0.0-beta.8-commit.
|
|
11
|
+
var version = "1.0.0-beta.8-commit.165d0b1";
|
|
12
12
|
var description = "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.";
|
|
13
13
|
|
|
14
14
|
//#endregion
|
|
@@ -34,8 +34,8 @@ var init_utils = __esm({ "src/builtin-plugin/utils.ts"() {} });
|
|
|
34
34
|
function modulePreloadPolyfillPlugin(config) {
|
|
35
35
|
return new BuiltinPlugin("builtin:module-preload-polyfill", config);
|
|
36
36
|
}
|
|
37
|
-
function dynamicImportVarsPlugin() {
|
|
38
|
-
return new BuiltinPlugin("builtin:dynamic-import-vars");
|
|
37
|
+
function dynamicImportVarsPlugin(config) {
|
|
38
|
+
return new BuiltinPlugin("builtin:dynamic-import-vars", config);
|
|
39
39
|
}
|
|
40
40
|
function importGlobPlugin(config) {
|
|
41
41
|
return new BuiltinPlugin("builtin:import-glob", config);
|
|
@@ -62,10 +62,7 @@ function buildImportAnalysisPlugin(config) {
|
|
|
62
62
|
return new BuiltinPlugin("builtin:build-import-analysis", config);
|
|
63
63
|
}
|
|
64
64
|
function viteResolvePlugin(config) {
|
|
65
|
-
const builtinPlugin = new BuiltinPlugin("builtin:vite-resolve",
|
|
66
|
-
...config,
|
|
67
|
-
runtime: process.versions.deno ? "deno" : process.versions.bun ? "bun" : "node"
|
|
68
|
-
});
|
|
65
|
+
const builtinPlugin = new BuiltinPlugin("builtin:vite-resolve", config);
|
|
69
66
|
return makeBuiltinPluginCallable(builtinPlugin);
|
|
70
67
|
}
|
|
71
68
|
function moduleFederationPlugin(config) {
|
|
@@ -633,10 +630,9 @@ var init_validator = __esm({ "src/utils/validator.ts"() {
|
|
|
633
630
|
configurationFieldConflict: v.pipe(v.optional(v.boolean()), v.description("Whether to emit warning when detecting configuration field conflict"))
|
|
634
631
|
});
|
|
635
632
|
MinifyOptionsSchema = v.strictObject({
|
|
636
|
-
mangle: v.boolean(),
|
|
637
|
-
compress: v.boolean(),
|
|
638
|
-
|
|
639
|
-
removeWhitespace: v.boolean()
|
|
633
|
+
mangle: v.optional(v.boolean()),
|
|
634
|
+
compress: v.optional(v.boolean()),
|
|
635
|
+
removeWhitespace: v.optional(v.boolean())
|
|
640
636
|
});
|
|
641
637
|
ResolveOptionsSchema = v.strictObject({
|
|
642
638
|
alias: v.optional(v.record(v.string(), v.union([v.string(), v.array(v.string())]))),
|
|
@@ -819,8 +815,13 @@ var init_validator = __esm({ "src/utils/validator.ts"() {
|
|
|
819
815
|
inlineDynamicImports: v.pipe(v.optional(v.boolean()), v.description("Inline dynamic imports")),
|
|
820
816
|
advancedChunks: v.optional(AdvancedChunksSchema),
|
|
821
817
|
comments: v.pipe(v.optional(v.union([v.literal("none"), v.literal("preserve-legal")])), v.description("Control comments in the output")),
|
|
818
|
+
plugins: v.optional(v.custom(() => true)),
|
|
819
|
+
polyfillRequire: v.pipe(v.optional(v.boolean()), v.description("Disable require polyfill injection")),
|
|
822
820
|
target: v.pipe(v.optional(v.enum(ESTarget)), v.description("The JavaScript target environment")),
|
|
823
|
-
|
|
821
|
+
hoistTransitiveImports: v.optional(v.custom((input) => {
|
|
822
|
+
if (input) return false;
|
|
823
|
+
return true;
|
|
824
|
+
}, () => `The 'true' value is not supported`))
|
|
824
825
|
});
|
|
825
826
|
getAddonDescription = (placement, wrapper) => {
|
|
826
827
|
return `Code to insert the ${colors.bold(placement)} of the bundled file (${colors.bold(wrapper)} the wrapper function)`;
|
|
@@ -850,7 +851,8 @@ var init_validator = __esm({ "src/utils/validator.ts"() {
|
|
|
850
851
|
}), [
|
|
851
852
|
"sourcemapIgnoreList",
|
|
852
853
|
"sourcemapPathTransform",
|
|
853
|
-
"plugins"
|
|
854
|
+
"plugins",
|
|
855
|
+
"hoistTransitiveImports"
|
|
854
856
|
]);
|
|
855
857
|
CliOptionsSchema = v.strictObject({
|
|
856
858
|
config: v.pipe(v.optional(v.union([v.string(), v.boolean()])), v.description("Path to the config file (default: `rolldown.config.js`)")),
|
|
@@ -964,27 +966,6 @@ function joinNewLine(s1, s2) {
|
|
|
964
966
|
}
|
|
965
967
|
var init_error = __esm({ "src/utils/error.ts"() {} });
|
|
966
968
|
|
|
967
|
-
//#endregion
|
|
968
|
-
//#region src/utils/resolved-external.ts
|
|
969
|
-
function transformResolvedExternal(bindingResolvedExternal$1) {
|
|
970
|
-
switch (bindingResolvedExternal$1.type) {
|
|
971
|
-
case "Bool": return bindingResolvedExternal$1.field0;
|
|
972
|
-
case "Absolute": return "absolute";
|
|
973
|
-
case "Relative": unreachable(`The PluginContext resolve result external couldn't be 'relative'`);
|
|
974
|
-
}
|
|
975
|
-
}
|
|
976
|
-
function bindingResolvedExternal(external) {
|
|
977
|
-
if (typeof external === "boolean") return {
|
|
978
|
-
type: "Bool",
|
|
979
|
-
field0: external
|
|
980
|
-
};
|
|
981
|
-
if (external === "absolute") return { type: "Absolute" };
|
|
982
|
-
if (external === "relative") return { type: "Relative" };
|
|
983
|
-
}
|
|
984
|
-
var init_resolved_external = __esm({ "src/utils/resolved-external.ts"() {
|
|
985
|
-
init_misc();
|
|
986
|
-
} });
|
|
987
|
-
|
|
988
969
|
//#endregion
|
|
989
970
|
//#region src/utils/transform-module-info.ts
|
|
990
971
|
function transformModuleInfo(info, option) {
|
|
@@ -1107,7 +1088,6 @@ var init_plugin_context = __esm({ "src/plugin/plugin-context.ts"() {
|
|
|
1107
1088
|
init_minimal_plugin_context();
|
|
1108
1089
|
init_asset_source();
|
|
1109
1090
|
init_misc();
|
|
1110
|
-
init_resolved_external();
|
|
1111
1091
|
init_transform_side_effects();
|
|
1112
1092
|
PluginContextImpl = class extends MinimalPluginContextImpl {
|
|
1113
1093
|
getModuleInfo;
|
|
@@ -1164,7 +1144,7 @@ var init_plugin_context = __esm({ "src/plugin/plugin-context.ts"() {
|
|
|
1164
1144
|
const info = this.data.getModuleOption(res.id) || {};
|
|
1165
1145
|
return {
|
|
1166
1146
|
...res,
|
|
1167
|
-
external:
|
|
1147
|
+
external: res.external === "relative" ? unreachable(`The PluginContext resolve result external couldn't be 'relative'`) : res.external,
|
|
1168
1148
|
...info
|
|
1169
1149
|
};
|
|
1170
1150
|
}
|
|
@@ -1279,7 +1259,7 @@ function bindingifyResolveId(args) {
|
|
|
1279
1259
|
if (ret == null) return;
|
|
1280
1260
|
if (ret === false) return {
|
|
1281
1261
|
id: specifier,
|
|
1282
|
-
external:
|
|
1262
|
+
external: true,
|
|
1283
1263
|
normalizeExternalId: true
|
|
1284
1264
|
};
|
|
1285
1265
|
if (typeof ret === "string") return {
|
|
@@ -1293,7 +1273,7 @@ function bindingifyResolveId(args) {
|
|
|
1293
1273
|
});
|
|
1294
1274
|
return {
|
|
1295
1275
|
id: ret.id,
|
|
1296
|
-
external:
|
|
1276
|
+
external: ret.external,
|
|
1297
1277
|
normalizeExternalId: false,
|
|
1298
1278
|
sideEffects: bindingifySideEffects(exist.moduleSideEffects)
|
|
1299
1279
|
};
|
|
@@ -1312,12 +1292,12 @@ function bindingifyResolveDynamicImport(args) {
|
|
|
1312
1292
|
if (ret == null) return;
|
|
1313
1293
|
if (ret === false) return {
|
|
1314
1294
|
id: specifier,
|
|
1315
|
-
external:
|
|
1295
|
+
external: true
|
|
1316
1296
|
};
|
|
1317
1297
|
if (typeof ret === "string") return { id: ret };
|
|
1318
1298
|
const result = {
|
|
1319
1299
|
id: ret.id,
|
|
1320
|
-
external:
|
|
1300
|
+
external: ret.external
|
|
1321
1301
|
};
|
|
1322
1302
|
if (ret.moduleSideEffects !== null) result.sideEffects = bindingifySideEffects(ret.moduleSideEffects);
|
|
1323
1303
|
args.pluginContextData.updateModuleOption(ret.id, {
|
|
@@ -1408,7 +1388,6 @@ var init_bindingify_build_hooks = __esm({ "src/plugin/bindingify-build-hooks.ts"
|
|
|
1408
1388
|
init_normalized_input_options();
|
|
1409
1389
|
init_sourcemap();
|
|
1410
1390
|
init_error();
|
|
1411
|
-
init_resolved_external();
|
|
1412
1391
|
init_transform_module_info();
|
|
1413
1392
|
init_transform_side_effects();
|
|
1414
1393
|
init_transform_sourcemap();
|
|
@@ -2299,9 +2278,12 @@ var init_plugin_context_data = __esm({ "src/plugin/plugin-context-data.ts"() {
|
|
|
2299
2278
|
//#region src/utils/normalize-string-or-regex.ts
|
|
2300
2279
|
function normalizedStringOrRegex(pattern) {
|
|
2301
2280
|
if (!pattern) return void 0;
|
|
2302
|
-
if (!
|
|
2281
|
+
if (!isReadonlyArray(pattern)) return [pattern];
|
|
2303
2282
|
return pattern;
|
|
2304
2283
|
}
|
|
2284
|
+
function isReadonlyArray(input) {
|
|
2285
|
+
return Array.isArray(input);
|
|
2286
|
+
}
|
|
2305
2287
|
var init_normalize_string_or_regex = __esm({ "src/utils/normalize-string-or-regex.ts"() {} });
|
|
2306
2288
|
|
|
2307
2289
|
//#endregion
|
|
@@ -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-DROW_mqO.cjs');
|
|
4
4
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
5
5
|
const __valibot_to_json_schema = require_chunk.__toESM(require("@valibot/to-json-schema"));
|
|
6
6
|
const ansis = require_chunk.__toESM(require("ansis"));
|
|
@@ -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.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
|
|
@@ -40,8 +40,8 @@ var BuiltinPlugin = class {
|
|
|
40
40
|
function modulePreloadPolyfillPlugin(config) {
|
|
41
41
|
return new BuiltinPlugin("builtin:module-preload-polyfill", config);
|
|
42
42
|
}
|
|
43
|
-
function dynamicImportVarsPlugin() {
|
|
44
|
-
return new BuiltinPlugin("builtin:dynamic-import-vars");
|
|
43
|
+
function dynamicImportVarsPlugin(config) {
|
|
44
|
+
return new BuiltinPlugin("builtin:dynamic-import-vars", config);
|
|
45
45
|
}
|
|
46
46
|
function importGlobPlugin(config) {
|
|
47
47
|
return new BuiltinPlugin("builtin:import-glob", config);
|
|
@@ -68,10 +68,7 @@ function buildImportAnalysisPlugin(config) {
|
|
|
68
68
|
return new BuiltinPlugin("builtin:build-import-analysis", config);
|
|
69
69
|
}
|
|
70
70
|
function viteResolvePlugin(config) {
|
|
71
|
-
const builtinPlugin = new BuiltinPlugin("builtin:vite-resolve",
|
|
72
|
-
...config,
|
|
73
|
-
runtime: process.versions.deno ? "deno" : process.versions.bun ? "bun" : "node"
|
|
74
|
-
});
|
|
71
|
+
const builtinPlugin = new BuiltinPlugin("builtin:vite-resolve", config);
|
|
75
72
|
return makeBuiltinPluginCallable(builtinPlugin);
|
|
76
73
|
}
|
|
77
74
|
function moduleFederationPlugin(config) {
|
|
@@ -550,10 +547,9 @@ const ChecksOptionsSchema = valibot.strictObject({
|
|
|
550
547
|
configurationFieldConflict: valibot.pipe(valibot.optional(valibot.boolean()), valibot.description("Whether to emit warning when detecting configuration field conflict"))
|
|
551
548
|
});
|
|
552
549
|
const MinifyOptionsSchema = valibot.strictObject({
|
|
553
|
-
mangle: valibot.boolean(),
|
|
554
|
-
compress: valibot.boolean(),
|
|
555
|
-
|
|
556
|
-
removeWhitespace: valibot.boolean()
|
|
550
|
+
mangle: valibot.optional(valibot.boolean()),
|
|
551
|
+
compress: valibot.optional(valibot.boolean()),
|
|
552
|
+
removeWhitespace: valibot.optional(valibot.boolean())
|
|
557
553
|
});
|
|
558
554
|
const ResolveOptionsSchema = valibot.strictObject({
|
|
559
555
|
alias: valibot.optional(valibot.record(valibot.string(), valibot.union([valibot.string(), valibot.array(valibot.string())]))),
|
|
@@ -736,8 +732,13 @@ const OutputOptionsSchema = valibot.strictObject({
|
|
|
736
732
|
inlineDynamicImports: valibot.pipe(valibot.optional(valibot.boolean()), valibot.description("Inline dynamic imports")),
|
|
737
733
|
advancedChunks: valibot.optional(AdvancedChunksSchema),
|
|
738
734
|
comments: valibot.pipe(valibot.optional(valibot.union([valibot.literal("none"), valibot.literal("preserve-legal")])), valibot.description("Control comments in the output")),
|
|
735
|
+
plugins: valibot.optional(valibot.custom(() => true)),
|
|
736
|
+
polyfillRequire: valibot.pipe(valibot.optional(valibot.boolean()), valibot.description("Disable require polyfill injection")),
|
|
739
737
|
target: valibot.pipe(valibot.optional(valibot.enum(ESTarget)), valibot.description("The JavaScript target environment")),
|
|
740
|
-
|
|
738
|
+
hoistTransitiveImports: valibot.optional(valibot.custom((input) => {
|
|
739
|
+
if (input) return false;
|
|
740
|
+
return true;
|
|
741
|
+
}, () => `The 'true' value is not supported`))
|
|
741
742
|
});
|
|
742
743
|
const getAddonDescription = (placement, wrapper) => {
|
|
743
744
|
return `Code to insert the ${ansis.default.bold(placement)} of the bundled file (${ansis.default.bold(wrapper)} the wrapper function)`;
|
|
@@ -767,7 +768,8 @@ const OutputCliOptionsSchema = valibot.omit(valibot.strictObject({
|
|
|
767
768
|
}), [
|
|
768
769
|
"sourcemapIgnoreList",
|
|
769
770
|
"sourcemapPathTransform",
|
|
770
|
-
"plugins"
|
|
771
|
+
"plugins",
|
|
772
|
+
"hoistTransitiveImports"
|
|
771
773
|
]);
|
|
772
774
|
const CliOptionsSchema = valibot.strictObject({
|
|
773
775
|
config: valibot.pipe(valibot.optional(valibot.union([valibot.string(), valibot.boolean()])), valibot.description("Path to the config file (default: `rolldown.config.js`)")),
|
|
@@ -916,24 +918,6 @@ function joinNewLine(s1, s2) {
|
|
|
916
918
|
return s1.replace(/\n+$/, "") + "\n" + s2.replace(/^\n+/, "");
|
|
917
919
|
}
|
|
918
920
|
|
|
919
|
-
//#endregion
|
|
920
|
-
//#region src/utils/resolved-external.ts
|
|
921
|
-
function transformResolvedExternal(bindingResolvedExternal$1) {
|
|
922
|
-
switch (bindingResolvedExternal$1.type) {
|
|
923
|
-
case "Bool": return bindingResolvedExternal$1.field0;
|
|
924
|
-
case "Absolute": return "absolute";
|
|
925
|
-
case "Relative": unreachable(`The PluginContext resolve result external couldn't be 'relative'`);
|
|
926
|
-
}
|
|
927
|
-
}
|
|
928
|
-
function bindingResolvedExternal(external) {
|
|
929
|
-
if (typeof external === "boolean") return {
|
|
930
|
-
type: "Bool",
|
|
931
|
-
field0: external
|
|
932
|
-
};
|
|
933
|
-
if (external === "absolute") return { type: "Absolute" };
|
|
934
|
-
if (external === "relative") return { type: "Relative" };
|
|
935
|
-
}
|
|
936
|
-
|
|
937
921
|
//#endregion
|
|
938
922
|
//#region src/utils/transform-module-info.ts
|
|
939
923
|
function transformModuleInfo(info, option) {
|
|
@@ -1093,7 +1077,7 @@ var PluginContextImpl = class extends MinimalPluginContextImpl {
|
|
|
1093
1077
|
const info = this.data.getModuleOption(res.id) || {};
|
|
1094
1078
|
return {
|
|
1095
1079
|
...res,
|
|
1096
|
-
external:
|
|
1080
|
+
external: res.external === "relative" ? unreachable(`The PluginContext resolve result external couldn't be 'relative'`) : res.external,
|
|
1097
1081
|
...info
|
|
1098
1082
|
};
|
|
1099
1083
|
}
|
|
@@ -1201,7 +1185,7 @@ function bindingifyResolveId(args) {
|
|
|
1201
1185
|
if (ret == null) return;
|
|
1202
1186
|
if (ret === false) return {
|
|
1203
1187
|
id: specifier,
|
|
1204
|
-
external:
|
|
1188
|
+
external: true,
|
|
1205
1189
|
normalizeExternalId: true
|
|
1206
1190
|
};
|
|
1207
1191
|
if (typeof ret === "string") return {
|
|
@@ -1215,7 +1199,7 @@ function bindingifyResolveId(args) {
|
|
|
1215
1199
|
});
|
|
1216
1200
|
return {
|
|
1217
1201
|
id: ret.id,
|
|
1218
|
-
external:
|
|
1202
|
+
external: ret.external,
|
|
1219
1203
|
normalizeExternalId: false,
|
|
1220
1204
|
sideEffects: bindingifySideEffects(exist.moduleSideEffects)
|
|
1221
1205
|
};
|
|
@@ -1234,12 +1218,12 @@ function bindingifyResolveDynamicImport(args) {
|
|
|
1234
1218
|
if (ret == null) return;
|
|
1235
1219
|
if (ret === false) return {
|
|
1236
1220
|
id: specifier,
|
|
1237
|
-
external:
|
|
1221
|
+
external: true
|
|
1238
1222
|
};
|
|
1239
1223
|
if (typeof ret === "string") return { id: ret };
|
|
1240
1224
|
const result = {
|
|
1241
1225
|
id: ret.id,
|
|
1242
|
-
external:
|
|
1226
|
+
external: ret.external
|
|
1243
1227
|
};
|
|
1244
1228
|
if (ret.moduleSideEffects !== null) result.sideEffects = bindingifySideEffects(ret.moduleSideEffects);
|
|
1245
1229
|
args.pluginContextData.updateModuleOption(ret.id, {
|
|
@@ -2157,9 +2141,12 @@ var PluginContextData = class {
|
|
|
2157
2141
|
//#region src/utils/normalize-string-or-regex.ts
|
|
2158
2142
|
function normalizedStringOrRegex(pattern) {
|
|
2159
2143
|
if (!pattern) return void 0;
|
|
2160
|
-
if (!
|
|
2144
|
+
if (!isReadonlyArray(pattern)) return [pattern];
|
|
2161
2145
|
return pattern;
|
|
2162
2146
|
}
|
|
2147
|
+
function isReadonlyArray(input) {
|
|
2148
|
+
return Array.isArray(input);
|
|
2149
|
+
}
|
|
2163
2150
|
|
|
2164
2151
|
//#endregion
|
|
2165
2152
|
//#region src/utils/bindingify-input-options.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rolldown",
|
|
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
|
"type": "commonjs",
|
|
6
6
|
"homepage": "https://rolldown.rs/",
|
|
@@ -82,13 +82,13 @@
|
|
|
82
82
|
"dtsHeader": "type MaybePromise<T> = T | Promise<T>\ntype Nullable<T> = T | null | undefined\ntype VoidNullable<T = void> = T | null | undefined | void\nexport type BindingStringOrRegex = string | RegExp\n\n"
|
|
83
83
|
},
|
|
84
84
|
"dependencies": {
|
|
85
|
-
"@oxc-project/types": "0.
|
|
85
|
+
"@oxc-project/types": "0.66.0",
|
|
86
86
|
"@valibot/to-json-schema": "1.0.0",
|
|
87
87
|
"ansis": "^3.17.0",
|
|
88
88
|
"valibot": "1.0.0"
|
|
89
89
|
},
|
|
90
90
|
"peerDependencies": {
|
|
91
|
-
"@oxc-project/runtime": "0.
|
|
91
|
+
"@oxc-project/runtime": "0.66.0"
|
|
92
92
|
},
|
|
93
93
|
"peerDependenciesMeta": {
|
|
94
94
|
"@oxc-project/runtime": {
|
|
@@ -107,7 +107,7 @@
|
|
|
107
107
|
"fs-extra": "^11.2.0",
|
|
108
108
|
"glob": "^11.0.0",
|
|
109
109
|
"locate-character": "^3.0.0",
|
|
110
|
-
"oxc-parser": "^0.
|
|
110
|
+
"oxc-parser": "^0.66.0",
|
|
111
111
|
"pathe": "^2.0.3",
|
|
112
112
|
"remeda": "^2.10.0",
|
|
113
113
|
"rolldown-plugin-dts": "^0.7.12",
|
|
@@ -120,21 +120,21 @@
|
|
|
120
120
|
"typescript": "^5.7.3",
|
|
121
121
|
"unbuild": "^3.0.0",
|
|
122
122
|
"@rolldown/testing": "0.0.1",
|
|
123
|
-
"rolldown": "1.0.0-beta.8-commit.
|
|
123
|
+
"rolldown": "1.0.0-beta.8-commit.165d0b1"
|
|
124
124
|
},
|
|
125
125
|
"optionalDependencies": {
|
|
126
|
-
"@rolldown/binding-darwin-arm64": "1.0.0-beta.8-commit.
|
|
127
|
-
"@rolldown/binding-
|
|
128
|
-
"@rolldown/binding-
|
|
129
|
-
"@rolldown/binding-
|
|
130
|
-
"@rolldown/binding-linux-arm64-gnu": "1.0.0-beta.8-commit.
|
|
131
|
-
"@rolldown/binding-linux-
|
|
132
|
-
"@rolldown/binding-linux-x64-gnu": "1.0.0-beta.8-commit.
|
|
133
|
-
"@rolldown/binding-linux-
|
|
134
|
-
"@rolldown/binding-wasm32-wasi": "1.0.0-beta.8-commit.
|
|
135
|
-
"@rolldown/binding-win32-
|
|
136
|
-
"@rolldown/binding-win32-
|
|
137
|
-
"@rolldown/binding-win32-x64-msvc": "1.0.0-beta.8-commit.
|
|
126
|
+
"@rolldown/binding-darwin-arm64": "1.0.0-beta.8-commit.165d0b1",
|
|
127
|
+
"@rolldown/binding-freebsd-x64": "1.0.0-beta.8-commit.165d0b1",
|
|
128
|
+
"@rolldown/binding-linux-arm-gnueabihf": "1.0.0-beta.8-commit.165d0b1",
|
|
129
|
+
"@rolldown/binding-darwin-x64": "1.0.0-beta.8-commit.165d0b1",
|
|
130
|
+
"@rolldown/binding-linux-arm64-gnu": "1.0.0-beta.8-commit.165d0b1",
|
|
131
|
+
"@rolldown/binding-linux-arm64-musl": "1.0.0-beta.8-commit.165d0b1",
|
|
132
|
+
"@rolldown/binding-linux-x64-gnu": "1.0.0-beta.8-commit.165d0b1",
|
|
133
|
+
"@rolldown/binding-linux-x64-musl": "1.0.0-beta.8-commit.165d0b1",
|
|
134
|
+
"@rolldown/binding-wasm32-wasi": "1.0.0-beta.8-commit.165d0b1",
|
|
135
|
+
"@rolldown/binding-win32-ia32-msvc": "1.0.0-beta.8-commit.165d0b1",
|
|
136
|
+
"@rolldown/binding-win32-arm64-msvc": "1.0.0-beta.8-commit.165d0b1",
|
|
137
|
+
"@rolldown/binding-win32-x64-msvc": "1.0.0-beta.8-commit.165d0b1"
|
|
138
138
|
},
|
|
139
139
|
"scripts": {
|
|
140
140
|
"# Scrips for binding #": "_",
|