@rolldown/browser 1.0.0-beta.49 → 1.0.0-beta.50
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.mjs +6 -6
- package/dist/config.d.mts +3 -3
- package/dist/config.mjs +3 -3
- package/dist/experimental-index.browser.mjs +1 -1
- package/dist/experimental-index.d.mts +4 -4
- package/dist/experimental-index.mjs +2 -2
- package/dist/filter-index.d.mts +3 -3
- package/dist/index.browser.mjs +1 -1
- package/dist/index.d.mts +3 -3
- package/dist/index.mjs +2 -2
- package/dist/parallel-plugin-worker.mjs +2 -2
- package/dist/parallel-plugin.d.mts +3 -3
- package/dist/parse-ast-index.d.mts +1 -1
- package/dist/parse-ast-index.mjs +1 -1
- package/dist/plugins-index.d.mts +3 -3
- package/dist/rolldown-binding.wasm32-wasi.wasm +0 -0
- package/dist/shared/{binding-B4uTNiw2.d.mts → binding-BTup3pHG.d.mts} +37 -2
- package/dist/shared/{constructors-CaN9lKj2.d.mts → constructors-B7IHT8j4.d.mts} +2 -2
- package/dist/shared/{define-config-BAQ9c-hh.d.mts → define-config-DiSv-kgF.d.mts} +2 -2
- package/dist/shared/{load-config-DQI-2sfE.mjs → load-config-BqnLKlUM.mjs} +1 -1
- package/dist/shared/{parse-ast-index-D9jH_38U.mjs → parse-ast-index-DtI4JSVR.mjs} +1 -1
- package/dist/shared/{prompt-Ckjl2FdJ.mjs → prompt-CjFmA1DF.mjs} +1 -1
- package/dist/shared/{src-CZ_U2fML.mjs → src-D0x2a_iO.mjs} +9 -9
- package/dist/shared/{utils-CduIqa7h.d.mts → utils-BKVJO2vQ.d.mts} +1 -1
- package/dist/{src-CnMyHYgB.js → src-dUoCuQap.js} +9 -9
- package/package.json +1 -1
package/dist/cli.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { C as version, S as description, _ as getOutputCliKeys, b as styleText$1, g as getInputCliKeys, h as getCliSchemaInfo, i as watch, o as rolldown, v as validateCliOptions, w as onExit } from "./shared/src-
|
|
1
|
+
import { C as version, S as description, _ as getOutputCliKeys, b as styleText$1, g as getInputCliKeys, h as getCliSchemaInfo, i as watch, o as rolldown, v as validateCliOptions, w as onExit } from "./shared/src-D0x2a_iO.mjs";
|
|
2
2
|
import "./shared/logs-CPsamAuj.mjs";
|
|
3
3
|
import "./shared/normalize-string-or-regex-CbDij6KB.mjs";
|
|
4
4
|
import { d as arraify } from "./shared/composable-filters-CBpK2Fbc.mjs";
|
|
5
|
-
import "./shared/parse-ast-index-
|
|
6
|
-
import { t as loadConfig } from "./shared/load-config-
|
|
5
|
+
import "./shared/parse-ast-index-DtI4JSVR.mjs";
|
|
6
|
+
import { t as loadConfig } from "./shared/load-config-BqnLKlUM.mjs";
|
|
7
7
|
import path, { sep } from "node:path";
|
|
8
8
|
import { formatWithOptions, parseArgs } from "node:util";
|
|
9
9
|
import process$1 from "node:process";
|
|
@@ -948,7 +948,7 @@ function createConsola(options$1 = {}) {
|
|
|
948
948
|
defaults: { level },
|
|
949
949
|
stdout: process.stdout,
|
|
950
950
|
stderr: process.stderr,
|
|
951
|
-
prompt: (...args) => import("./shared/prompt-
|
|
951
|
+
prompt: (...args) => import("./shared/prompt-CjFmA1DF.mjs").then((m) => m.prompt(...args)),
|
|
952
952
|
reporters: options$1.reporters || [options$1.fancy ?? !(T || R) ? new FancyReporter() : new BasicReporter()],
|
|
953
953
|
...options$1
|
|
954
954
|
});
|
|
@@ -1235,7 +1235,7 @@ function getClearScreenFunction(options$1) {
|
|
|
1235
1235
|
}
|
|
1236
1236
|
|
|
1237
1237
|
//#endregion
|
|
1238
|
-
//#region \0@oxc-project+runtime@0.
|
|
1238
|
+
//#region \0@oxc-project+runtime@0.97.0/helpers/usingCtx.js
|
|
1239
1239
|
function _usingCtx() {
|
|
1240
1240
|
var r$1 = "function" == typeof SuppressedError ? SuppressedError : function(r$2, e$1) {
|
|
1241
1241
|
var n$2 = Error();
|
|
@@ -1547,7 +1547,7 @@ function checkNodeVersion(nodeVersion) {
|
|
|
1547
1547
|
//#region src/cli/index.ts
|
|
1548
1548
|
if (!checkNodeVersion(process$1.versions.node)) logger.warn(`You are using Node.js ${process$1.versions.node}. Rolldown requires Node.js version 20.19+ or 22.12+. Please upgrade your Node.js version.`);
|
|
1549
1549
|
async function main() {
|
|
1550
|
-
const { rawArgs
|
|
1550
|
+
const { rawArgs, ...cliOptions } = parseCliArguments();
|
|
1551
1551
|
if (cliOptions.environment) {
|
|
1552
1552
|
const environment = Array.isArray(cliOptions.environment) ? cliOptions.environment : [cliOptions.environment];
|
|
1553
1553
|
for (const argument of environment) for (const pair of argument.split(",")) {
|
package/dist/config.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as ConfigExport, t as defineConfig } from "./shared/define-config-
|
|
2
|
-
import "./shared/binding-
|
|
3
|
-
import "./shared/utils-
|
|
1
|
+
import { n as ConfigExport, t as defineConfig } from "./shared/define-config-DiSv-kgF.mjs";
|
|
2
|
+
import "./shared/binding-BTup3pHG.mjs";
|
|
3
|
+
import "./shared/utils-BKVJO2vQ.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/utils/load-config.d.ts
|
|
6
6
|
declare function loadConfig(configPath: string): Promise<ConfigExport>;
|
package/dist/config.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { C as version, r as defineConfig } from "./shared/src-
|
|
1
|
+
import { C as version, r as defineConfig } from "./shared/src-D0x2a_iO.mjs";
|
|
2
2
|
import "./shared/logs-CPsamAuj.mjs";
|
|
3
3
|
import "./shared/normalize-string-or-regex-CbDij6KB.mjs";
|
|
4
4
|
import "./shared/composable-filters-CBpK2Fbc.mjs";
|
|
5
|
-
import "./shared/parse-ast-index-
|
|
6
|
-
import { t as loadConfig } from "./shared/load-config-
|
|
5
|
+
import "./shared/parse-ast-index-DtI4JSVR.mjs";
|
|
6
|
+
import { t as loadConfig } from "./shared/load-config-BqnLKlUM.mjs";
|
|
7
7
|
|
|
8
8
|
//#region src/config.ts
|
|
9
9
|
const VERSION = version;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as createBundlerOptions, d as transformToRollupOutput, f as bindingifySourcemap, l as normalizeBindingResult, m as PluginDriver, p as validateOption, s as RolldownBuild, u as unwrapBindingResult } from "./src-
|
|
1
|
+
import { c as createBundlerOptions, d as transformToRollupOutput, f as bindingifySourcemap, l as normalizeBindingResult, m as PluginDriver, p as validateOption, s as RolldownBuild, u as unwrapBindingResult } from "./src-dUoCuQap.js";
|
|
2
2
|
import { n as BuiltinPlugin, t as normalizedStringOrRegex } from "./normalize-string-or-regex-d47jXr3r.js";
|
|
3
3
|
import { _ as wasmHelperPlugin, a as importGlobPlugin, c as loadFallbackPlugin, d as reactRefreshWrapperPlugin, f as reporterPlugin, g as wasmFallbackPlugin, h as viteResolvePlugin, i as htmlInlineProxyPlugin, l as manifestPlugin, m as viteHtmlPlugin, n as dynamicImportVarsPlugin, o as isolatedDeclarationPlugin, p as viteCSSPostPlugin, s as jsonPlugin, t as buildImportAnalysisPlugin, u as modulePreloadPolyfillPlugin, v as webWorkerPostPlugin } from "./constructors-EhfoQfqh.js";
|
|
4
4
|
import { BindingBundler, BindingDevEngine, BindingRebuildStrategy, BindingRebuildStrategy as BindingRebuildStrategy$1, ResolverFactory, isolatedDeclaration, minify, moduleRunnerTransform, parseAsync, parseSync, shutdownAsyncRuntime, startAsyncRuntime, transform } from "./rolldown-binding.wasi-browser.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Dt as freeExternalMemory, H as defineParallelPlugin, M as SourceMapInput, Tt as RolldownOutput, o as InputOptions, yt as OutputOptions } from "./shared/define-config-
|
|
2
|
-
import { A as IsolatedDeclarationsOptions, B as ResolverFactory, F as NapiResolveOptions, G as moduleRunnerTransform, H as TransformResult, I as ParseResult, J as transform, K as parseAsync, L as ParserOptions, N as MinifyOptions, P as MinifyResult, S as BindingViteCssPluginConfig, U as isolatedDeclaration, V as TransformOptions, W as minify, b as BindingTransformPluginConfig, h as BindingRebuildStrategy, i as BindingClientHmrUpdate, j as IsolatedDeclarationsResult, q as parseSync, t as BindingAssetPluginConfig, x as BindingUrlResolver, z as ResolveResult } from "./shared/binding-
|
|
3
|
-
import { t as BuiltinPlugin } from "./shared/utils-
|
|
4
|
-
import { _ as wasmHelperPlugin, a as importGlobPlugin, c as loadFallbackPlugin, d as reactRefreshWrapperPlugin, f as reporterPlugin, g as wasmFallbackPlugin, h as viteResolvePlugin, i as htmlInlineProxyPlugin, l as manifestPlugin, m as viteHtmlPlugin, n as dynamicImportVarsPlugin, o as isolatedDeclarationPlugin, p as viteCSSPostPlugin, s as jsonPlugin, t as buildImportAnalysisPlugin, u as modulePreloadPolyfillPlugin, v as webWorkerPostPlugin } from "./shared/constructors-
|
|
1
|
+
import { Dt as freeExternalMemory, H as defineParallelPlugin, M as SourceMapInput, Tt as RolldownOutput, o as InputOptions, yt as OutputOptions } from "./shared/define-config-DiSv-kgF.mjs";
|
|
2
|
+
import { A as IsolatedDeclarationsOptions, B as ResolverFactory, F as NapiResolveOptions, G as moduleRunnerTransform, H as TransformResult, I as ParseResult, J as transform, K as parseAsync, L as ParserOptions, N as MinifyOptions, P as MinifyResult, S as BindingViteCssPluginConfig, U as isolatedDeclaration, V as TransformOptions, W as minify, b as BindingTransformPluginConfig, h as BindingRebuildStrategy, i as BindingClientHmrUpdate, j as IsolatedDeclarationsResult, q as parseSync, t as BindingAssetPluginConfig, x as BindingUrlResolver, z as ResolveResult } from "./shared/binding-BTup3pHG.mjs";
|
|
3
|
+
import { t as BuiltinPlugin } from "./shared/utils-BKVJO2vQ.mjs";
|
|
4
|
+
import { _ as wasmHelperPlugin, a as importGlobPlugin, c as loadFallbackPlugin, d as reactRefreshWrapperPlugin, f as reporterPlugin, g as wasmFallbackPlugin, h as viteResolvePlugin, i as htmlInlineProxyPlugin, l as manifestPlugin, m as viteHtmlPlugin, n as dynamicImportVarsPlugin, o as isolatedDeclarationPlugin, p as viteCSSPostPlugin, s as jsonPlugin, t as buildImportAnalysisPlugin, u as modulePreloadPolyfillPlugin, v as webWorkerPostPlugin } from "./shared/constructors-B7IHT8j4.mjs";
|
|
5
5
|
|
|
6
6
|
//#region src/api/dev/dev-options.d.ts
|
|
7
7
|
type DevOnHmrUpdates = (result: Error | {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { c as createBundlerOptions, d as normalizeBindingResult, f as unwrapBindingResult, m as bindingifySourcemap, p as transformToRollupOutput, s as RolldownBuild, x as PluginDriver, y as validateOption } from "./shared/src-
|
|
1
|
+
import { c as createBundlerOptions, d as normalizeBindingResult, f as unwrapBindingResult, m as bindingifySourcemap, p as transformToRollupOutput, s as RolldownBuild, x as PluginDriver, y as validateOption } from "./shared/src-D0x2a_iO.mjs";
|
|
2
2
|
import "./shared/logs-CPsamAuj.mjs";
|
|
3
3
|
import { n as BuiltinPlugin, t as normalizedStringOrRegex } from "./shared/normalize-string-or-regex-CbDij6KB.mjs";
|
|
4
4
|
import "./shared/composable-filters-CBpK2Fbc.mjs";
|
|
5
|
-
import "./shared/parse-ast-index-
|
|
5
|
+
import "./shared/parse-ast-index-DtI4JSVR.mjs";
|
|
6
6
|
import { _ as wasmHelperPlugin, a as importGlobPlugin, c as loadFallbackPlugin, d as reactRefreshWrapperPlugin, f as reporterPlugin, g as wasmFallbackPlugin, h as viteResolvePlugin, i as htmlInlineProxyPlugin, l as manifestPlugin, m as viteHtmlPlugin, n as dynamicImportVarsPlugin, o as isolatedDeclarationPlugin, p as viteCSSPostPlugin, s as jsonPlugin, t as buildImportAnalysisPlugin, u as modulePreloadPolyfillPlugin, v as webWorkerPostPlugin } from "./shared/constructors-DcEzB0nc.mjs";
|
|
7
7
|
import { BindingBundler, BindingDevEngine, BindingRebuildStrategy, BindingRebuildStrategy as BindingRebuildStrategy$1, ResolverFactory, isolatedDeclaration, minify, moduleRunnerTransform, parseAsync, parseSync, shutdownAsyncRuntime, startAsyncRuntime, transform } from "./rolldown-binding.wasi.cjs";
|
|
8
8
|
import { pathToFileURL } from "node:url";
|
package/dist/filter-index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { k as withFilter } from "./shared/define-config-
|
|
2
|
-
import "./shared/binding-
|
|
3
|
-
import "./shared/utils-
|
|
1
|
+
import { k as withFilter } from "./shared/define-config-DiSv-kgF.mjs";
|
|
2
|
+
import "./shared/binding-BTup3pHG.mjs";
|
|
3
|
+
import "./shared/utils-BKVJO2vQ.mjs";
|
|
4
4
|
import { and, code, exclude, id, include, moduleType, not, or, queries, query } from "@rolldown/pluginutils";
|
|
5
5
|
export { and, code, exclude, id, include, moduleType, not, or, queries, query, withFilter };
|
package/dist/index.browser.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as build, i as watch, n as VERSION, o as rolldown, r as defineConfig, t as BindingMagicString } from "./src-
|
|
1
|
+
import { a as build, i as watch, n as VERSION, o as rolldown, r as defineConfig, t as BindingMagicString } from "./src-dUoCuQap.js";
|
|
2
2
|
import "./normalize-string-or-regex-d47jXr3r.js";
|
|
3
3
|
|
|
4
4
|
export { BindingMagicString, VERSION, build, defineConfig, rolldown, watch };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as NormalizedOutputOptions, A as VERSION, At as LogLevel, B as PluginContext, C as ResolveIdResult, Ct as RenderedChunk, D as SourceDescription, E as RolldownPluginOption, Et as SourceMap, F as TreeshakingOptions, Ft as RollupLogWithString, G as GeneralHookFilter, I as TransformPluginContext, J as BufferEncoding, K as HookFilter, L as EmittedAsset, M as SourceMapInput, Mt as LogOrStringHandler, N as RolldownOptionsFunction, Nt as RollupError, O as TransformResult, Ot as ModuleInfo, P as OutputBundle, Pt as RollupLog, Q as InternalModuleFormat, R as EmittedFile, S as ResolveIdExtraOptions, St as OutputChunk, T as RolldownPlugin, Tt as RolldownOutput, U as MinimalPluginContext, V as DefineParallelPluginResult, W as PluginContextMeta, X as RolldownFileStats, Y as RolldownDirectoryEntry, Z as RolldownFsModule, _ as ModuleType, _t as MinifyOptions, a as InputOption, at as RolldownWatcherEvent, b as PartialResolvedId, bt as PreRenderedAsset, c as OptimizationOptions, ct as RolldownBuild, d as CustomPluginOptions, dt as AddonFunction, et as NormalizedInputOptions, f as FunctionPluginHooks, ft as ChunkFileNamesFunction, g as ModuleOptions, gt as GlobalsFunction, h as LoadResult, ht as GeneratedCodePreset, i as ExternalOption, it as RolldownWatcher, j as ExistingRawSourceMap, jt as LogLevelOption, kt as SourcemapIgnoreListOption, l as WatcherOptions, lt as BuildOptions, m as ImportKind, mt as GeneratedCodeOptions, n as ConfigExport, nt as WarningHandlerWithDefault, o as InputOptions, ot as WatchOptions, p as HookFilterExtension, pt as ChunkingContext, q as ModuleTypeFilter, r as RolldownOptions, rt as watch, s as ModuleTypes, st as rolldown, t as defineConfig, tt as LoggingFunction, u as AsyncPluginHooks, ut as build, v as ObjectHook, vt as ModuleFormat, w as ResolvedId, wt as RenderedModule, x as Plugin, xt as OutputAsset, y as ParallelPluginHooks, yt as OutputOptions, z as GetModuleInfo } from "./shared/define-config-
|
|
2
|
-
import { R as PreRenderedChunk, d as BindingMagicString } from "./shared/binding-
|
|
3
|
-
import { o as PartialNull } from "./shared/utils-
|
|
1
|
+
import { $ as NormalizedOutputOptions, A as VERSION, At as LogLevel, B as PluginContext, C as ResolveIdResult, Ct as RenderedChunk, D as SourceDescription, E as RolldownPluginOption, Et as SourceMap, F as TreeshakingOptions, Ft as RollupLogWithString, G as GeneralHookFilter, I as TransformPluginContext, J as BufferEncoding, K as HookFilter, L as EmittedAsset, M as SourceMapInput, Mt as LogOrStringHandler, N as RolldownOptionsFunction, Nt as RollupError, O as TransformResult, Ot as ModuleInfo, P as OutputBundle, Pt as RollupLog, Q as InternalModuleFormat, R as EmittedFile, S as ResolveIdExtraOptions, St as OutputChunk, T as RolldownPlugin, Tt as RolldownOutput, U as MinimalPluginContext, V as DefineParallelPluginResult, W as PluginContextMeta, X as RolldownFileStats, Y as RolldownDirectoryEntry, Z as RolldownFsModule, _ as ModuleType, _t as MinifyOptions, a as InputOption, at as RolldownWatcherEvent, b as PartialResolvedId, bt as PreRenderedAsset, c as OptimizationOptions, ct as RolldownBuild, d as CustomPluginOptions, dt as AddonFunction, et as NormalizedInputOptions, f as FunctionPluginHooks, ft as ChunkFileNamesFunction, g as ModuleOptions, gt as GlobalsFunction, h as LoadResult, ht as GeneratedCodePreset, i as ExternalOption, it as RolldownWatcher, j as ExistingRawSourceMap, jt as LogLevelOption, kt as SourcemapIgnoreListOption, l as WatcherOptions, lt as BuildOptions, m as ImportKind, mt as GeneratedCodeOptions, n as ConfigExport, nt as WarningHandlerWithDefault, o as InputOptions, ot as WatchOptions, p as HookFilterExtension, pt as ChunkingContext, q as ModuleTypeFilter, r as RolldownOptions, rt as watch, s as ModuleTypes, st as rolldown, t as defineConfig, tt as LoggingFunction, u as AsyncPluginHooks, ut as build, v as ObjectHook, vt as ModuleFormat, w as ResolvedId, wt as RenderedModule, x as Plugin, xt as OutputAsset, y as ParallelPluginHooks, yt as OutputOptions, z as GetModuleInfo } from "./shared/define-config-DiSv-kgF.mjs";
|
|
2
|
+
import { R as PreRenderedChunk, d as BindingMagicString } from "./shared/binding-BTup3pHG.mjs";
|
|
3
|
+
import { o as PartialNull } from "./shared/utils-BKVJO2vQ.mjs";
|
|
4
4
|
export { AddonFunction, AsyncPluginHooks, BindingMagicString, BufferEncoding, BuildOptions, ChunkFileNamesFunction, ChunkingContext, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GeneralHookFilter, GeneratedCodeOptions, GeneratedCodePreset, GetModuleInfo, GlobalsFunction, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, LoadResult, LogLevel, LogLevelOption, LogOrStringHandler, LoggingFunction, MinifyOptions, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, ModuleTypes, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OptimizationOptions, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, PreRenderedChunk, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownDirectoryEntry, RolldownFileStats, RolldownFsModule, RolldownOptions, RolldownOptionsFunction, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RolldownWatcherEvent, RollupError, RollupLog, RollupLogWithString, SourceDescription, SourceMap, SourceMapInput, SourcemapIgnoreListOption, TransformPluginContext, TransformResult, TreeshakingOptions, VERSION, WarningHandlerWithDefault, WatchOptions, WatcherOptions, build, defineConfig, rolldown, watch };
|
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { a as build, i as watch, n as VERSION, o as rolldown, r as defineConfig, t as BindingMagicString } from "./shared/src-
|
|
1
|
+
import { a as build, i as watch, n as VERSION, o as rolldown, r as defineConfig, t as BindingMagicString } from "./shared/src-D0x2a_iO.mjs";
|
|
2
2
|
import "./shared/logs-CPsamAuj.mjs";
|
|
3
3
|
import "./shared/normalize-string-or-regex-CbDij6KB.mjs";
|
|
4
4
|
import "./shared/composable-filters-CBpK2Fbc.mjs";
|
|
5
|
-
import "./shared/parse-ast-index-
|
|
5
|
+
import "./shared/parse-ast-index-DtI4JSVR.mjs";
|
|
6
6
|
|
|
7
7
|
export { BindingMagicString, VERSION, build, defineConfig, rolldown, watch };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { l as PluginContextData, u as bindingifyPlugin } from "./shared/src-
|
|
1
|
+
import { l as PluginContextData, u as bindingifyPlugin } from "./shared/src-D0x2a_iO.mjs";
|
|
2
2
|
import "./shared/logs-CPsamAuj.mjs";
|
|
3
3
|
import "./shared/normalize-string-or-regex-CbDij6KB.mjs";
|
|
4
4
|
import "./shared/composable-filters-CBpK2Fbc.mjs";
|
|
5
|
-
import "./shared/parse-ast-index-
|
|
5
|
+
import "./shared/parse-ast-index-DtI4JSVR.mjs";
|
|
6
6
|
import { parentPort, workerData } from "node:worker_threads";
|
|
7
7
|
import { registerPlugins } from "./rolldown-binding.wasi.cjs";
|
|
8
8
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { x as Plugin } from "./shared/define-config-
|
|
2
|
-
import "./shared/binding-
|
|
3
|
-
import { i as MaybePromise } from "./shared/utils-
|
|
1
|
+
import { x as Plugin } from "./shared/define-config-DiSv-kgF.mjs";
|
|
2
|
+
import "./shared/binding-BTup3pHG.mjs";
|
|
3
|
+
import { i as MaybePromise } from "./shared/utils-BKVJO2vQ.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/plugin/parallel-plugin-implementation.d.ts
|
|
6
6
|
type ParallelPluginImplementation = Plugin;
|
package/dist/parse-ast-index.mjs
CHANGED
package/dist/plugins-index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { _ as BindingReplacePluginConfig } from "./shared/binding-
|
|
2
|
-
import { t as BuiltinPlugin } from "./shared/utils-
|
|
3
|
-
import { r as esmExternalRequirePlugin } from "./shared/constructors-
|
|
1
|
+
import { _ as BindingReplacePluginConfig } from "./shared/binding-BTup3pHG.mjs";
|
|
2
|
+
import { t as BuiltinPlugin } from "./shared/utils-BKVJO2vQ.mjs";
|
|
3
|
+
import { r as esmExternalRequirePlugin } from "./shared/constructors-B7IHT8j4.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/builtin-plugin/replace-plugin.d.ts
|
|
6
6
|
|
|
Binary file
|
|
@@ -73,6 +73,8 @@ interface CompressOptions {
|
|
|
73
73
|
dropLabels?: Array<string>;
|
|
74
74
|
/** Limit the maximum number of iterations for debugging purpose. */
|
|
75
75
|
maxIterations?: number;
|
|
76
|
+
/** Treeshake options. */
|
|
77
|
+
treeshake?: TreeShakeOptions;
|
|
76
78
|
}
|
|
77
79
|
interface CompressOptionsKeepNames {
|
|
78
80
|
/**
|
|
@@ -125,7 +127,7 @@ interface MangleOptionsKeepNames {
|
|
|
125
127
|
/** Minify synchronously. */
|
|
126
128
|
declare function minify(filename: string, sourceText: string, options?: MinifyOptions | undefined | null): MinifyResult;
|
|
127
129
|
interface MinifyOptions {
|
|
128
|
-
/** Use when minifying an
|
|
130
|
+
/** Use when minifying an ES module. */
|
|
129
131
|
module?: boolean;
|
|
130
132
|
compress?: boolean | CompressOptions;
|
|
131
133
|
mangle?: boolean | MangleOptions;
|
|
@@ -137,6 +139,39 @@ interface MinifyResult {
|
|
|
137
139
|
map?: SourceMap;
|
|
138
140
|
errors: Array<OxcError>;
|
|
139
141
|
}
|
|
142
|
+
interface TreeShakeOptions {
|
|
143
|
+
/**
|
|
144
|
+
* Whether to respect the pure annotations.
|
|
145
|
+
*
|
|
146
|
+
* Pure annotations are comments that mark an expression as pure.
|
|
147
|
+
* For example: @__PURE__ or #__NO_SIDE_EFFECTS__.
|
|
148
|
+
*
|
|
149
|
+
* @default true
|
|
150
|
+
*/
|
|
151
|
+
annotations?: boolean;
|
|
152
|
+
/**
|
|
153
|
+
* Whether to treat this function call as pure.
|
|
154
|
+
*
|
|
155
|
+
* This function is called for normal function calls, new calls, and
|
|
156
|
+
* tagged template calls.
|
|
157
|
+
*/
|
|
158
|
+
manualPureFunctions?: Array<string>;
|
|
159
|
+
/**
|
|
160
|
+
* Whether property read accesses have side effects.
|
|
161
|
+
*
|
|
162
|
+
* @default 'always'
|
|
163
|
+
*/
|
|
164
|
+
propertyReadSideEffects?: boolean | 'always';
|
|
165
|
+
/**
|
|
166
|
+
* Whether accessing a global variable has side effects.
|
|
167
|
+
*
|
|
168
|
+
* Accessing a non-existing global variable will throw an error.
|
|
169
|
+
* Global variable may be a getter that has side effects.
|
|
170
|
+
*
|
|
171
|
+
* @default true
|
|
172
|
+
*/
|
|
173
|
+
unknownGlobalSideEffects?: boolean;
|
|
174
|
+
}
|
|
140
175
|
interface Comment {
|
|
141
176
|
type: 'Line' | 'Block';
|
|
142
177
|
value: string;
|
|
@@ -787,7 +822,7 @@ interface JsxOptions {
|
|
|
787
822
|
/**
|
|
788
823
|
* Enables `@babel/plugin-transform-react-pure-annotations`.
|
|
789
824
|
*
|
|
790
|
-
* It will mark top-level React method calls as pure for tree shaking.
|
|
825
|
+
* It will mark JSX elements and top-level React method calls as pure for tree shaking.
|
|
791
826
|
*
|
|
792
827
|
* @see {@link https://babeljs.io/docs/en/babel-plugin-transform-react-pure-annotations}
|
|
793
828
|
*
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as BindingViteCssPostPluginConfig, E as BindingWasmHelperPluginConfig, T as BindingViteResolvePluginConfig, a as BindingDynamicImportVarsPluginConfig, c as BindingImportGlobPluginConfig, f as BindingManifestPluginConfig, l as BindingIsolatedDeclarationPluginConfig, m as BindingReactRefreshWrapperPluginConfig, n as BindingBuildImportAnalysisPluginConfig, o as BindingEsmExternalRequirePluginConfig, p as BindingModulePreloadPolyfillPluginConfig, u as BindingJsonPluginConfig, v as BindingReporterPluginConfig, w as BindingViteHtmlPluginConfig } from "./binding-
|
|
2
|
-
import { s as StringOrRegExp, t as BuiltinPlugin } from "./utils-
|
|
1
|
+
import { C as BindingViteCssPostPluginConfig, E as BindingWasmHelperPluginConfig, T as BindingViteResolvePluginConfig, a as BindingDynamicImportVarsPluginConfig, c as BindingImportGlobPluginConfig, f as BindingManifestPluginConfig, l as BindingIsolatedDeclarationPluginConfig, m as BindingReactRefreshWrapperPluginConfig, n as BindingBuildImportAnalysisPluginConfig, o as BindingEsmExternalRequirePluginConfig, p as BindingModulePreloadPolyfillPluginConfig, u as BindingJsonPluginConfig, v as BindingReporterPluginConfig, w as BindingViteHtmlPluginConfig } from "./binding-BTup3pHG.mjs";
|
|
2
|
+
import { s as StringOrRegExp, t as BuiltinPlugin } from "./utils-BKVJO2vQ.mjs";
|
|
3
3
|
|
|
4
4
|
//#region src/builtin-plugin/constructors.d.ts
|
|
5
5
|
declare function modulePreloadPolyfillPlugin(config?: BindingModulePreloadPolyfillPluginConfig): BuiltinPlugin;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { D as BindingWatcherBundler, L as ParserOptions, M as JsxOptions, N as MinifyOptions$1, O as BindingWatcherEvent, R as PreRenderedChunk, V as TransformOptions$1, d as BindingMagicString, g as BindingRenderedChunk, k as ExternalMemoryStatus, s as BindingHookResolveIdExtraArgs, y as BindingTransformHookExtraArgs } from "./binding-
|
|
2
|
-
import { a as NullValue, i as MaybePromise, n as MakeAsync, o as PartialNull, r as MaybeArray, s as StringOrRegExp, t as BuiltinPlugin } from "./utils-
|
|
1
|
+
import { D as BindingWatcherBundler, L as ParserOptions, M as JsxOptions, N as MinifyOptions$1, O as BindingWatcherEvent, R as PreRenderedChunk, V as TransformOptions$1, d as BindingMagicString, g as BindingRenderedChunk, k as ExternalMemoryStatus, s as BindingHookResolveIdExtraArgs, y as BindingTransformHookExtraArgs } from "./binding-BTup3pHG.mjs";
|
|
2
|
+
import { a as NullValue, i as MaybePromise, n as MakeAsync, o as PartialNull, r as MaybeArray, s as StringOrRegExp, t as BuiltinPlugin } from "./utils-BKVJO2vQ.mjs";
|
|
3
3
|
import { Program } from "@oxc-project/types";
|
|
4
4
|
import { TopLevelFilterExpression } from "@rolldown/pluginutils";
|
|
5
5
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { l as locate, n as error, s as logParseError, u as getCodeFrame } from "./logs-CPsamAuj.mjs";
|
|
2
2
|
import { parseAsync, parseSync } from "../rolldown-binding.wasi.cjs";
|
|
3
3
|
|
|
4
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
4
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.97.0/node_modules/oxc-parser/src-js/wrap.js
|
|
5
5
|
function wrap$1(result) {
|
|
6
6
|
let program, module, comments, errors;
|
|
7
7
|
return {
|
|
@@ -446,7 +446,7 @@ var AD = Object.defineProperty, pD = (t, u$1, F$1) => u$1 in t ? AD(t, u$1, {
|
|
|
446
446
|
var x = class {
|
|
447
447
|
constructor(u$1, F$1 = true) {
|
|
448
448
|
h(this, "input"), h(this, "output"), h(this, "_abortSignal"), h(this, "rl"), h(this, "opts"), h(this, "_render"), h(this, "_track", false), h(this, "_prevFrame", ""), h(this, "_subscribers", /* @__PURE__ */ new Map()), h(this, "_cursor", 0), h(this, "state", "initial"), h(this, "error", ""), h(this, "value");
|
|
449
|
-
const { input: e$1 = stdin, output: s = stdout, render: i, signal: D
|
|
449
|
+
const { input: e$1 = stdin, output: s = stdout, render: i, signal: D, ...C$1 } = u$1;
|
|
450
450
|
this.opts = C$1, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = i.bind(this), this._track = F$1, this._abortSignal = D, this.input = e$1, this.output = s;
|
|
451
451
|
}
|
|
452
452
|
unsubscribe() {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { a as logInvalidLogPosition, c as logPluginError, i as logInputHookInOutputPlugin, n as error, o as logMultiplyNotifyOption, r as logCycleLoading, t as augmentCodeLocation } from "./logs-CPsamAuj.mjs";
|
|
2
2
|
import { n as BuiltinPlugin, r as bindingifyBuiltInPlugin, t as normalizedStringOrRegex } from "./normalize-string-or-regex-CbDij6KB.mjs";
|
|
3
3
|
import { a as include, c as or, d as arraify, g as unsupported, h as unreachable, i as id, m as unimplemented, n as code, o as moduleType, p as noop, r as exclude, t as and } from "./composable-filters-CBpK2Fbc.mjs";
|
|
4
|
-
import { t as parseAst } from "./parse-ast-index-
|
|
4
|
+
import { t as parseAst } from "./parse-ast-index-DtI4JSVR.mjs";
|
|
5
5
|
import { Worker, isMainThread } from "node:worker_threads";
|
|
6
6
|
import { BindingAttachDebugInfo, BindingBundler, BindingChunkModuleOrderBy, BindingLogLevel, BindingMagicString, BindingMagicString as BindingMagicString$1, BindingPluginOrder, BindingPropertyReadSideEffects, BindingPropertyWriteSideEffects, BindingWatcher, ParallelJsPluginRegistry, initTraceSubscriber, shutdownAsyncRuntime, startAsyncRuntime } from "../rolldown-binding.wasi.cjs";
|
|
7
7
|
import path from "node:path";
|
|
@@ -220,7 +220,7 @@ if (isMainThread) {
|
|
|
220
220
|
|
|
221
221
|
//#endregion
|
|
222
222
|
//#region package.json
|
|
223
|
-
var version = "1.0.0-beta.
|
|
223
|
+
var version = "1.0.0-beta.50";
|
|
224
224
|
var description$1 = "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.";
|
|
225
225
|
|
|
226
226
|
//#endregion
|
|
@@ -335,7 +335,7 @@ function normalizeHook(hook) {
|
|
|
335
335
|
meta: {}
|
|
336
336
|
};
|
|
337
337
|
if (typeof hook === "object" && hook !== null) {
|
|
338
|
-
const { handler, order
|
|
338
|
+
const { handler, order, ...options } = hook;
|
|
339
339
|
return {
|
|
340
340
|
handler,
|
|
341
341
|
options,
|
|
@@ -2238,7 +2238,7 @@ function bindingAssetSource(source) {
|
|
|
2238
2238
|
}
|
|
2239
2239
|
|
|
2240
2240
|
//#endregion
|
|
2241
|
-
//#region \0@oxc-project+runtime@0.
|
|
2241
|
+
//#region \0@oxc-project+runtime@0.97.0/helpers/decorate.js
|
|
2242
2242
|
function __decorate(decorators, target, key, desc) {
|
|
2243
2243
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
2244
2244
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
@@ -3923,7 +3923,7 @@ function normalizeTransformOptions(inputOptions) {
|
|
|
3923
3923
|
const dropLabels = transform?.dropLabels;
|
|
3924
3924
|
let oxcTransformOptions;
|
|
3925
3925
|
if (transform) {
|
|
3926
|
-
const { define: _define, inject: _inject, dropLabels: _dropLabels
|
|
3926
|
+
const { define: _define, inject: _inject, dropLabels: _dropLabels, ...rest } = transform;
|
|
3927
3927
|
if (Object.keys(rest).length > 0) {
|
|
3928
3928
|
if (rest.jsx === false) rest.jsx = "disable";
|
|
3929
3929
|
oxcTransformOptions = rest;
|
|
@@ -4038,7 +4038,7 @@ function bindingifyExperimental(experimental) {
|
|
|
4038
4038
|
function bindingifyResolve(resolve) {
|
|
4039
4039
|
const yarnPnp = typeof process === "object" && !!process.versions?.pnp;
|
|
4040
4040
|
if (resolve) {
|
|
4041
|
-
const { alias, extensionAlias
|
|
4041
|
+
const { alias, extensionAlias, ...rest } = resolve;
|
|
4042
4042
|
return {
|
|
4043
4043
|
alias: alias ? Object.entries(alias).map(([name, replacement]) => ({
|
|
4044
4044
|
find: name,
|
|
@@ -4273,11 +4273,11 @@ function bindingifyAdvancedChunks(advancedChunks, manualChunks) {
|
|
|
4273
4273
|
return manualChunks(moduleId, { getModuleInfo: (id$1) => ctx.getModuleInfo(id$1) });
|
|
4274
4274
|
} }] };
|
|
4275
4275
|
if (advancedChunks == null) return;
|
|
4276
|
-
const { groups
|
|
4276
|
+
const { groups, ...restAdvancedChunks } = advancedChunks;
|
|
4277
4277
|
return {
|
|
4278
4278
|
...restAdvancedChunks,
|
|
4279
4279
|
groups: groups?.map((group) => {
|
|
4280
|
-
const { name
|
|
4280
|
+
const { name, ...restGroup } = group;
|
|
4281
4281
|
return {
|
|
4282
4282
|
...restGroup,
|
|
4283
4283
|
name: typeof name === "function" ? (id$1, ctx) => name(id$1, new ChunkingContextImpl(ctx)) : name
|
|
@@ -4443,7 +4443,7 @@ const rolldown = async (input) => {
|
|
|
4443
4443
|
async function build(options) {
|
|
4444
4444
|
if (Array.isArray(options)) return Promise.all(options.map((opts) => build(opts)));
|
|
4445
4445
|
else {
|
|
4446
|
-
const { output, write = true
|
|
4446
|
+
const { output, write = true, ...inputOptions } = options;
|
|
4447
4447
|
const build$1 = await rolldown(inputOptions);
|
|
4448
4448
|
try {
|
|
4449
4449
|
if (write) return await build$1.write(output);
|
|
@@ -2,7 +2,7 @@ import { a as augmentCodeLocation, c as logInputHookInOutputPlugin, d as logNoFi
|
|
|
2
2
|
import { BindingAttachDebugInfo, BindingBundler, BindingChunkModuleOrderBy, BindingLogLevel, BindingMagicString, BindingMagicString as BindingMagicString$1, BindingPluginOrder, BindingPropertyReadSideEffects, BindingPropertyWriteSideEffects, BindingWatcher, parseSync, shutdownAsyncRuntime, startAsyncRuntime } from "./rolldown-binding.wasi-browser.js";
|
|
3
3
|
|
|
4
4
|
//#region package.json
|
|
5
|
-
var version = "1.0.0-beta.
|
|
5
|
+
var version = "1.0.0-beta.50";
|
|
6
6
|
|
|
7
7
|
//#endregion
|
|
8
8
|
//#region ../../node_modules/.pnpm/pathe@2.0.3/node_modules/pathe/dist/shared/pathe.M-eThtNZ.mjs
|
|
@@ -583,7 +583,7 @@ function normalizeHook(hook) {
|
|
|
583
583
|
meta: {}
|
|
584
584
|
};
|
|
585
585
|
if (typeof hook === "object" && hook !== null) {
|
|
586
|
-
const { handler, order
|
|
586
|
+
const { handler, order, ...options } = hook;
|
|
587
587
|
return {
|
|
588
588
|
handler,
|
|
589
589
|
options,
|
|
@@ -2377,7 +2377,7 @@ function bindingAssetSource(source) {
|
|
|
2377
2377
|
}
|
|
2378
2378
|
|
|
2379
2379
|
//#endregion
|
|
2380
|
-
//#region \0@oxc-project+runtime@0.
|
|
2380
|
+
//#region \0@oxc-project+runtime@0.97.0/helpers/decorate.js
|
|
2381
2381
|
function __decorate(decorators, target, key, desc) {
|
|
2382
2382
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
2383
2383
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
@@ -2766,7 +2766,7 @@ var RolldownOutputImpl = class extends PlainObjectLike {
|
|
|
2766
2766
|
__decorate([lazyProp], RolldownOutputImpl.prototype, "output", null);
|
|
2767
2767
|
|
|
2768
2768
|
//#endregion
|
|
2769
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
2769
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.97.0/node_modules/oxc-parser/src-js/wrap.js
|
|
2770
2770
|
function wrap$1(result) {
|
|
2771
2771
|
let program, module, comments, errors;
|
|
2772
2772
|
return {
|
|
@@ -4222,7 +4222,7 @@ function normalizeTransformOptions(inputOptions) {
|
|
|
4222
4222
|
const dropLabels = transform?.dropLabels;
|
|
4223
4223
|
let oxcTransformOptions;
|
|
4224
4224
|
if (transform) {
|
|
4225
|
-
const { define: _define, inject: _inject, dropLabels: _dropLabels
|
|
4225
|
+
const { define: _define, inject: _inject, dropLabels: _dropLabels, ...rest } = transform;
|
|
4226
4226
|
if (Object.keys(rest).length > 0) {
|
|
4227
4227
|
if (rest.jsx === false) rest.jsx = "disable";
|
|
4228
4228
|
oxcTransformOptions = rest;
|
|
@@ -4337,7 +4337,7 @@ function bindingifyExperimental(experimental) {
|
|
|
4337
4337
|
function bindingifyResolve(resolve$1) {
|
|
4338
4338
|
const yarnPnp = typeof process === "object" && !!process.versions?.pnp;
|
|
4339
4339
|
if (resolve$1) {
|
|
4340
|
-
const { alias, extensionAlias
|
|
4340
|
+
const { alias, extensionAlias, ...rest } = resolve$1;
|
|
4341
4341
|
return {
|
|
4342
4342
|
alias: alias ? Object.entries(alias).map(([name, replacement]) => ({
|
|
4343
4343
|
find: name,
|
|
@@ -4572,11 +4572,11 @@ function bindingifyAdvancedChunks(advancedChunks, manualChunks) {
|
|
|
4572
4572
|
return manualChunks(moduleId, { getModuleInfo: (id$1) => ctx.getModuleInfo(id$1) });
|
|
4573
4573
|
} }] };
|
|
4574
4574
|
if (advancedChunks == null) return;
|
|
4575
|
-
const { groups
|
|
4575
|
+
const { groups, ...restAdvancedChunks } = advancedChunks;
|
|
4576
4576
|
return {
|
|
4577
4577
|
...restAdvancedChunks,
|
|
4578
4578
|
groups: groups?.map((group) => {
|
|
4579
|
-
const { name
|
|
4579
|
+
const { name, ...restGroup } = group;
|
|
4580
4580
|
return {
|
|
4581
4581
|
...restGroup,
|
|
4582
4582
|
name: typeof name === "function" ? (id$1, ctx) => name(id$1, new ChunkingContextImpl(ctx)) : name
|
|
@@ -4680,7 +4680,7 @@ const rolldown = async (input) => {
|
|
|
4680
4680
|
async function build(options) {
|
|
4681
4681
|
if (Array.isArray(options)) return Promise.all(options.map((opts) => build(opts)));
|
|
4682
4682
|
else {
|
|
4683
|
-
const { output, write = true
|
|
4683
|
+
const { output, write = true, ...inputOptions } = options;
|
|
4684
4684
|
const build$1 = await rolldown(inputOptions);
|
|
4685
4685
|
try {
|
|
4686
4686
|
if (write) return await build$1.write(output);
|
package/package.json
CHANGED