rolldown 1.0.0-beta.54 → 1.0.0-beta.55
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-setup.mjs +2 -2
- package/dist/cli.mjs +19 -19
- package/dist/config.d.mts +2 -2
- package/dist/config.mjs +8 -8
- package/dist/experimental-index.d.mts +10 -4
- package/dist/experimental-index.mjs +14 -15
- package/dist/filter-index.d.mts +2 -2
- package/dist/filter-index.mjs +1 -1
- package/dist/get-log-filter.d.mts +7 -0
- package/dist/get-log-filter.mjs +48 -0
- package/dist/index.d.mts +3 -2
- package/dist/index.mjs +10 -14
- package/dist/parallel-plugin-worker.mjs +5 -5
- package/dist/parallel-plugin.d.mts +2 -2
- package/dist/parse-ast-index.d.mts +1 -1
- package/dist/parse-ast-index.mjs +2 -2
- package/dist/plugins-index.d.mts +3 -3
- package/dist/plugins-index.mjs +3 -3
- package/dist/shared/{binding-BgawCXFG.mjs → binding-DMnPPQ90.mjs} +51 -27
- package/dist/shared/{binding-yIBVkeOE.d.mts → binding-r9j8jqRV.d.mts} +2 -0
- package/dist/shared/{bindingify-input-options-DvsExmEF.mjs → bindingify-input-options-A-rLIOKA.mjs} +28 -22
- package/dist/shared/{constructors-DqAPGbqJ.mjs → constructors-BGI2r6Tk.mjs} +1 -1
- package/dist/shared/{constructors-BgO0Ou3T.d.mts → constructors-DO8UjlE5.d.mts} +2 -2
- package/dist/shared/{define-config-COJu-A7R.d.mts → define-config-MdVaFcie.d.mts} +15 -40
- package/dist/shared/{load-config--qXpT-nH.mjs → load-config-DnirbDRj.mjs} +1 -1
- package/dist/shared/logging-BpAvp7KV.d.mts +37 -0
- package/dist/shared/{normalize-string-or-regex-CF1OWLn9.mjs → normalize-string-or-regex-B4d0IHth.mjs} +6 -6
- package/dist/shared/{parse-ast-index-DeJDe-DO.mjs → parse-ast-index-CoZSRGeP.mjs} +4 -4
- package/dist/shared/{rolldown-BsTgRBvz.mjs → rolldown-BTFK71hw.mjs} +1 -1
- package/dist/shared/{rolldown-build-DtYoS8Tq.mjs → rolldown-build-CNW2eye_.mjs} +22 -15
- package/dist/shared/{watch-CfGzq0YA.mjs → watch-CKam-d6K.mjs} +11 -11
- package/package.json +19 -18
- /package/dist/shared/{define-config-DfeZGBEt.mjs → define-config-BF4P-Pum.mjs} +0 -0
- /package/dist/shared/{logs-CSQ_UMWp.mjs → logs-sGci9sux.mjs} +0 -0
- /package/dist/shared/{misc-CxyvWjTr.mjs → misc-DpjTMcQQ.mjs} +0 -0
- /package/dist/shared/{prompt-pmGBC3ws.mjs → prompt-CNt8OM9C.mjs} +0 -0
package/dist/cli-setup.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { t as require_binding } from "./shared/binding-
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./shared/binding-DMnPPQ90.mjs";
|
|
2
2
|
|
|
3
3
|
//#region src/cli/setup-index.ts
|
|
4
|
-
var import_binding = require_binding();
|
|
4
|
+
var import_binding = /* @__PURE__ */ __toESM(require_binding(), 1);
|
|
5
5
|
let isWatchMode = false;
|
|
6
6
|
for (let i = 0; i < process.argv.length; i++) {
|
|
7
7
|
const arg = process.argv[i];
|
package/dist/cli.mjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "./shared/binding-
|
|
2
|
-
import { n as onExit, t as watch } from "./shared/watch-
|
|
3
|
-
import { t as arraify } from "./shared/misc-
|
|
4
|
-
import { b as description, x as version } from "./shared/normalize-string-or-regex-
|
|
5
|
-
import { a as getOutputCliKeys, c as styleText$1, i as getInputCliKeys, o as validateCliOptions, r as getCliSchemaInfo } from "./shared/rolldown-build-
|
|
6
|
-
import "./shared/bindingify-input-options-
|
|
7
|
-
import "./shared/parse-ast-index-
|
|
8
|
-
import { t as rolldown } from "./shared/rolldown-
|
|
9
|
-
import { t as loadConfig } from "./shared/load-config
|
|
1
|
+
import "./shared/binding-DMnPPQ90.mjs";
|
|
2
|
+
import { n as onExit, t as watch } from "./shared/watch-CKam-d6K.mjs";
|
|
3
|
+
import { t as arraify } from "./shared/misc-DpjTMcQQ.mjs";
|
|
4
|
+
import { b as description, x as version } from "./shared/normalize-string-or-regex-B4d0IHth.mjs";
|
|
5
|
+
import { a as getOutputCliKeys, c as styleText$1, i as getInputCliKeys, o as validateCliOptions, r as getCliSchemaInfo } from "./shared/rolldown-build-CNW2eye_.mjs";
|
|
6
|
+
import "./shared/bindingify-input-options-A-rLIOKA.mjs";
|
|
7
|
+
import "./shared/parse-ast-index-CoZSRGeP.mjs";
|
|
8
|
+
import { t as rolldown } from "./shared/rolldown-BTFK71hw.mjs";
|
|
9
|
+
import { t as loadConfig } from "./shared/load-config-DnirbDRj.mjs";
|
|
10
10
|
import path, { sep } from "node:path";
|
|
11
11
|
import { formatWithOptions, parseArgs } from "node:util";
|
|
12
12
|
import process$1 from "node:process";
|
|
@@ -531,7 +531,7 @@ function getColor$1(color, fallback = "reset") {
|
|
|
531
531
|
return colors[color] || colors[fallback];
|
|
532
532
|
}
|
|
533
533
|
const ansiRegex$1 = [String.raw`[\u001B\u009B][[\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\d\/#&.:=?%@~_]+)*|[a-zA-Z\d]+(?:;[-a-zA-Z\d\/#&.:=?%@~_]*)*)?\u0007)`, String.raw`(?:(?:\d{1,4}(?:;\d{0,4})*)?[\dA-PR-TZcf-nq-uy=><~]))`].join("|");
|
|
534
|
-
function stripAnsi(text) {
|
|
534
|
+
function stripAnsi$1(text) {
|
|
535
535
|
return text.replace(new RegExp(ansiRegex$1, "g"), "");
|
|
536
536
|
}
|
|
537
537
|
const boxStylePresets = {
|
|
@@ -624,14 +624,14 @@ function box(text, _opts = {}) {
|
|
|
624
624
|
if (_color) for (const key in borderStyle) borderStyle[key] = _color(borderStyle[key]);
|
|
625
625
|
const paddingOffset = opts.style.padding % 2 === 0 ? opts.style.padding : opts.style.padding + 1;
|
|
626
626
|
const height = textLines.length + paddingOffset;
|
|
627
|
-
const width = Math.max(...textLines.map((line) => stripAnsi(line).length), opts.title ? stripAnsi(opts.title).length : 0) + paddingOffset;
|
|
627
|
+
const width = Math.max(...textLines.map((line) => stripAnsi$1(line).length), opts.title ? stripAnsi$1(opts.title).length : 0) + paddingOffset;
|
|
628
628
|
const widthOffset = width + paddingOffset;
|
|
629
629
|
const leftSpace = opts.style.marginLeft > 0 ? " ".repeat(opts.style.marginLeft) : "";
|
|
630
630
|
if (opts.style.marginTop > 0) boxLines.push("".repeat(opts.style.marginTop));
|
|
631
631
|
if (opts.title) {
|
|
632
632
|
const title = _color ? _color(opts.title) : opts.title;
|
|
633
|
-
const left = borderStyle.h.repeat(Math.floor((width - stripAnsi(opts.title).length) / 2));
|
|
634
|
-
const right = borderStyle.h.repeat(width - stripAnsi(opts.title).length - stripAnsi(left).length + paddingOffset);
|
|
633
|
+
const left = borderStyle.h.repeat(Math.floor((width - stripAnsi$1(opts.title).length) / 2));
|
|
634
|
+
const right = borderStyle.h.repeat(width - stripAnsi$1(opts.title).length - stripAnsi$1(left).length + paddingOffset);
|
|
635
635
|
boxLines.push(`${leftSpace}${borderStyle.tl}${left}${title}${right}${borderStyle.tr}`);
|
|
636
636
|
} else boxLines.push(`${leftSpace}${borderStyle.tl}${borderStyle.h.repeat(widthOffset)}${borderStyle.tr}`);
|
|
637
637
|
const valignOffset = opts.style.valign === "center" ? Math.floor((height - textLines.length) / 2) : opts.style.valign === "top" ? height - textLines.length - paddingOffset : height - textLines.length;
|
|
@@ -639,7 +639,7 @@ function box(text, _opts = {}) {
|
|
|
639
639
|
else {
|
|
640
640
|
const line = textLines[i$1 - valignOffset];
|
|
641
641
|
const left = " ".repeat(paddingOffset);
|
|
642
|
-
const right = " ".repeat(width - stripAnsi(line).length);
|
|
642
|
+
const right = " ".repeat(width - stripAnsi$1(line).length);
|
|
643
643
|
boxLines.push(`${leftSpace}${borderStyle.v}${left}${line}${right}${borderStyle.v}`);
|
|
644
644
|
}
|
|
645
645
|
boxLines.push(`${leftSpace}${borderStyle.bl}${borderStyle.h.repeat(widthOffset)}${borderStyle.br}`);
|
|
@@ -812,7 +812,7 @@ function ansiRegex({ onlyFirst = false } = {}) {
|
|
|
812
812
|
return new RegExp(pattern, onlyFirst ? void 0 : "g");
|
|
813
813
|
}
|
|
814
814
|
const regex = ansiRegex();
|
|
815
|
-
function stripAnsi
|
|
815
|
+
function stripAnsi(string) {
|
|
816
816
|
if (typeof string !== "string") throw new TypeError(`Expected a \`string\`, got \`${typeof string}\``);
|
|
817
817
|
return string.replace(regex, "");
|
|
818
818
|
}
|
|
@@ -841,7 +841,7 @@ const defaultIgnorableCodePointRegex = /^\p{Default_Ignorable_Code_Point}$/u;
|
|
|
841
841
|
function stringWidth$1(string, options$1 = {}) {
|
|
842
842
|
if (typeof string !== "string" || string.length === 0) return 0;
|
|
843
843
|
const { ambiguousIsNarrow = true, countAnsiEscapeCodes = false } = options$1;
|
|
844
|
-
if (!countAnsiEscapeCodes) string = stripAnsi
|
|
844
|
+
if (!countAnsiEscapeCodes) string = stripAnsi(string);
|
|
845
845
|
if (string.length === 0) return 0;
|
|
846
846
|
let width = 0;
|
|
847
847
|
const eastAsianWidthOptions = { ambiguousAsWide: !ambiguousIsNarrow };
|
|
@@ -894,7 +894,7 @@ const TYPE_ICONS = {
|
|
|
894
894
|
log: ""
|
|
895
895
|
};
|
|
896
896
|
function stringWidth(str) {
|
|
897
|
-
if (!(typeof Intl === "object") || !Intl.Segmenter) return stripAnsi(str).length;
|
|
897
|
+
if (!(typeof Intl === "object") || !Intl.Segmenter) return stripAnsi$1(str).length;
|
|
898
898
|
return stringWidth$1(str);
|
|
899
899
|
}
|
|
900
900
|
var FancyReporter = class extends BasicReporter {
|
|
@@ -951,7 +951,7 @@ function createConsola(options$1 = {}) {
|
|
|
951
951
|
defaults: { level },
|
|
952
952
|
stdout: process.stdout,
|
|
953
953
|
stderr: process.stderr,
|
|
954
|
-
prompt: (...args) => import("./shared/prompt-
|
|
954
|
+
prompt: (...args) => import("./shared/prompt-CNt8OM9C.mjs").then((m) => m.prompt(...args)),
|
|
955
955
|
reporters: options$1.reporters || [options$1.fancy ?? !(T || R) ? new FancyReporter() : new BasicReporter()],
|
|
956
956
|
...options$1
|
|
957
957
|
});
|
|
@@ -1238,7 +1238,7 @@ function getClearScreenFunction(options$1) {
|
|
|
1238
1238
|
}
|
|
1239
1239
|
|
|
1240
1240
|
//#endregion
|
|
1241
|
-
//#region \0@oxc-project+runtime@0.
|
|
1241
|
+
//#region \0@oxc-project+runtime@0.103.0/helpers/usingCtx.js
|
|
1242
1242
|
function _usingCtx() {
|
|
1243
1243
|
var r$1 = "function" == typeof SuppressedError ? SuppressedError : function(r$2, e$1) {
|
|
1244
1244
|
var n$2 = Error();
|
package/dist/config.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "./shared/
|
|
1
|
+
import "./shared/binding-r9j8jqRV.mjs";
|
|
2
|
+
import { n as ConfigExport, t as defineConfig } from "./shared/define-config-MdVaFcie.mjs";
|
|
3
3
|
|
|
4
4
|
//#region src/utils/load-config.d.ts
|
|
5
5
|
declare function loadConfig(configPath: string): Promise<ConfigExport>;
|
package/dist/config.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import "./shared/binding-
|
|
2
|
-
import { x as version } from "./shared/normalize-string-or-regex-
|
|
3
|
-
import "./shared/rolldown-build-
|
|
4
|
-
import "./shared/bindingify-input-options-
|
|
5
|
-
import "./shared/parse-ast-index-
|
|
6
|
-
import "./shared/rolldown-
|
|
7
|
-
import { t as defineConfig } from "./shared/define-config-
|
|
8
|
-
import { t as loadConfig } from "./shared/load-config
|
|
1
|
+
import "./shared/binding-DMnPPQ90.mjs";
|
|
2
|
+
import { x as version } from "./shared/normalize-string-or-regex-B4d0IHth.mjs";
|
|
3
|
+
import "./shared/rolldown-build-CNW2eye_.mjs";
|
|
4
|
+
import "./shared/bindingify-input-options-A-rLIOKA.mjs";
|
|
5
|
+
import "./shared/parse-ast-index-CoZSRGeP.mjs";
|
|
6
|
+
import "./shared/rolldown-BTFK71hw.mjs";
|
|
7
|
+
import { t as defineConfig } from "./shared/define-config-BF4P-Pum.mjs";
|
|
8
|
+
import { t as loadConfig } from "./shared/load-config-DnirbDRj.mjs";
|
|
9
9
|
|
|
10
10
|
//#region src/config.ts
|
|
11
11
|
const VERSION = version;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { a as viteDynamicImportVarsPlugin, c as viteJsonPlugin, d as viteReactRefreshWrapperPlugin, f as viteReporterPlugin, g as viteWebWorkerPostPlugin, h as viteWasmHelperPlugin, i as viteBuildImportAnalysisPlugin, l as viteLoadFallbackPlugin, m as viteWasmFallbackPlugin, n as isolatedDeclarationPlugin, o as viteHtmlInlineProxyPlugin, p as viteResolvePlugin, r as viteAssetImportMetaUrlPlugin, s as viteImportGlobPlugin, u as viteModulePreloadPolyfillPlugin } from "./shared/constructors-
|
|
1
|
+
import { $ as transformSync, B as ParserOptions, C as BindingViteManifestPluginConfig, G as TransformResult, H as ResolveResult, I as MinifyOptions, J as isolatedDeclarationSync, K as createTokioRuntime, L as MinifyResult, N as IsolatedDeclarationsOptions, O as BindingViteTransformPluginConfig, P as IsolatedDeclarationsResult, Q as transform, R as NapiResolveOptions, U as ResolverFactory, W as TransformOptions, X as minifySync, Y as minify, Z as moduleRunnerTransform, _ as BindingViteCssPostPluginConfig, b as BindingViteHtmlPluginConfig, c as BindingRebuildStrategy, f as BindingUrlResolver, g as BindingViteCssPluginConfig, m as BindingViteAssetPluginConfig, n as BindingBundleState, q as isolatedDeclaration, r as BindingClientHmrUpdate, z as ParseResult } from "./shared/binding-r9j8jqRV.mjs";
|
|
2
|
+
import { A as BuiltinPlugin, At as RolldownOutput, Dt as OutputChunk, F as OutputBundle, G as MinimalPluginContext, Mt as freeExternalMemory, N as SourceMapInput, W as defineParallelPlugin, o as InputOptions, tt as NormalizedOutputOptions, xt as OutputOptions } from "./shared/define-config-MdVaFcie.mjs";
|
|
3
|
+
import { a as viteDynamicImportVarsPlugin, c as viteJsonPlugin, d as viteReactRefreshWrapperPlugin, f as viteReporterPlugin, g as viteWebWorkerPostPlugin, h as viteWasmHelperPlugin, i as viteBuildImportAnalysisPlugin, l as viteLoadFallbackPlugin, m as viteWasmFallbackPlugin, n as isolatedDeclarationPlugin, o as viteHtmlInlineProxyPlugin, p as viteResolvePlugin, r as viteAssetImportMetaUrlPlugin, s as viteImportGlobPlugin, u as viteModulePreloadPolyfillPlugin } from "./shared/constructors-DO8UjlE5.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/api/dev/dev-options.d.ts
|
|
6
6
|
type DevOnHmrUpdates = (result: Error | {
|
|
@@ -191,4 +191,10 @@ type ViteManifestPluginConfig = Omit<BindingViteManifestPluginConfig, "isLegacy"
|
|
|
191
191
|
};
|
|
192
192
|
declare function viteManifestPlugin(config: ViteManifestPluginConfig): BuiltinPlugin;
|
|
193
193
|
//#endregion
|
|
194
|
-
|
|
194
|
+
//#region src/experimental-index.d.ts
|
|
195
|
+
declare const memfs: {
|
|
196
|
+
fs: any;
|
|
197
|
+
volume: any;
|
|
198
|
+
} | undefined;
|
|
199
|
+
//#endregion
|
|
200
|
+
export { type BindingClientHmrUpdate, BindingRebuildStrategy, DevEngine, type DevOptions, type DevWatchOptions, type IsolatedDeclarationsOptions, type IsolatedDeclarationsResult, type MinifyOptions, type MinifyResult, type ParseResult, type ParserOptions, type NapiResolveOptions as ResolveOptions, type ResolveResult, ResolverFactory, type TransformOptions, type TransformResult, type ViteHtmlPluginOptions, createTokioRuntime, defineParallelPlugin, dev, viteDynamicImportVarsPlugin as dynamicImportVarsPlugin, viteDynamicImportVarsPlugin, freeExternalMemory, viteImportGlobPlugin as importGlobPlugin, viteImportGlobPlugin, isolatedDeclaration, isolatedDeclarationPlugin, isolatedDeclarationSync, memfs, minify, minifySync, moduleRunnerTransform, parse, parseSync, scan, transform, transformSync, viteAliasPlugin, viteAssetImportMetaUrlPlugin, viteAssetPlugin, viteBuildImportAnalysisPlugin, viteCSSPlugin, viteCSSPostPlugin, viteHtmlInlineProxyPlugin, viteHtmlPlugin, viteJsonPlugin, viteLoadFallbackPlugin, viteManifestPlugin, viteModulePreloadPolyfillPlugin, viteReactRefreshWrapperPlugin, viteReporterPlugin, viteResolvePlugin, viteTransformPlugin, viteWasmFallbackPlugin, viteWasmHelperPlugin, viteWebWorkerPostPlugin };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { t as require_binding } from "./shared/binding-
|
|
2
|
-
import { d as bindingifySourcemap, n as BuiltinPlugin, t as normalizedStringOrRegex, u as transformToRollupOutput } from "./shared/normalize-string-or-regex-
|
|
3
|
-
import { l as PluginDriver, n as createBundlerOptions, s as validateOption, t as RolldownBuild } from "./shared/rolldown-build-
|
|
4
|
-
import { o as normalizeBindingResult, s as unwrapBindingResult } from "./shared/bindingify-input-options-
|
|
5
|
-
import { i as parseSync, r as parse } from "./shared/parse-ast-index-
|
|
6
|
-
import { a as viteDynamicImportVarsPlugin, c as viteJsonPlugin, d as viteReactRefreshWrapperPlugin, f as viteReporterPlugin, g as viteWebWorkerPostPlugin, h as viteWasmHelperPlugin, i as viteBuildImportAnalysisPlugin, l as viteLoadFallbackPlugin, m as viteWasmFallbackPlugin, n as isolatedDeclarationPlugin, o as viteHtmlInlineProxyPlugin, p as viteResolvePlugin, r as viteAssetImportMetaUrlPlugin, s as viteImportGlobPlugin, u as viteModulePreloadPolyfillPlugin } from "./shared/constructors-
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./shared/binding-DMnPPQ90.mjs";
|
|
2
|
+
import { d as bindingifySourcemap, n as BuiltinPlugin, t as normalizedStringOrRegex, u as transformToRollupOutput } from "./shared/normalize-string-or-regex-B4d0IHth.mjs";
|
|
3
|
+
import { l as PluginDriver, n as createBundlerOptions, s as validateOption, t as RolldownBuild } from "./shared/rolldown-build-CNW2eye_.mjs";
|
|
4
|
+
import { o as normalizeBindingResult, s as unwrapBindingResult } from "./shared/bindingify-input-options-A-rLIOKA.mjs";
|
|
5
|
+
import { i as parseSync, r as parse } from "./shared/parse-ast-index-CoZSRGeP.mjs";
|
|
6
|
+
import { a as viteDynamicImportVarsPlugin, c as viteJsonPlugin, d as viteReactRefreshWrapperPlugin, f as viteReporterPlugin, g as viteWebWorkerPostPlugin, h as viteWasmHelperPlugin, i as viteBuildImportAnalysisPlugin, l as viteLoadFallbackPlugin, m as viteWasmFallbackPlugin, n as isolatedDeclarationPlugin, o as viteHtmlInlineProxyPlugin, p as viteResolvePlugin, r as viteAssetImportMetaUrlPlugin, s as viteImportGlobPlugin, u as viteModulePreloadPolyfillPlugin } from "./shared/constructors-BGI2r6Tk.mjs";
|
|
7
7
|
import { pathToFileURL } from "node:url";
|
|
8
8
|
|
|
9
9
|
//#region src/api/dev/dev-engine.ts
|
|
10
|
-
var import_binding
|
|
10
|
+
var import_binding = /* @__PURE__ */ __toESM(require_binding(), 1);
|
|
11
11
|
var DevEngine = class DevEngine {
|
|
12
12
|
#inner;
|
|
13
13
|
#cachedBuildFinishPromise = null;
|
|
@@ -38,7 +38,7 @@ var DevEngine = class DevEngine {
|
|
|
38
38
|
}
|
|
39
39
|
userOnOutput(transformToRollupOutput(result));
|
|
40
40
|
} : void 0,
|
|
41
|
-
rebuildStrategy: devOptions.rebuildStrategy ? devOptions.rebuildStrategy === "always" ? import_binding
|
|
41
|
+
rebuildStrategy: devOptions.rebuildStrategy ? devOptions.rebuildStrategy === "always" ? import_binding.BindingRebuildStrategy.Always : devOptions.rebuildStrategy === "auto" ? import_binding.BindingRebuildStrategy.Auto : import_binding.BindingRebuildStrategy.Never : void 0,
|
|
42
42
|
watch: devOptions.watch && {
|
|
43
43
|
skipWrite: devOptions.watch.skipWrite,
|
|
44
44
|
usePolling: devOptions.watch.usePolling,
|
|
@@ -49,7 +49,7 @@ var DevEngine = class DevEngine {
|
|
|
49
49
|
debounceTickRate: devOptions.watch.debounceTickRate
|
|
50
50
|
}
|
|
51
51
|
};
|
|
52
|
-
return new DevEngine(new import_binding
|
|
52
|
+
return new DevEngine(new import_binding.BindingDevEngine(options.bundlerOptions, bindingDevOptions));
|
|
53
53
|
}
|
|
54
54
|
constructor(inner) {
|
|
55
55
|
this.#inner = inner;
|
|
@@ -132,7 +132,6 @@ function freeExternalMemory(handle, keepDataAlive = false) {
|
|
|
132
132
|
|
|
133
133
|
//#endregion
|
|
134
134
|
//#region src/api/experimental.ts
|
|
135
|
-
var import_binding$1 = require_binding();
|
|
136
135
|
/**
|
|
137
136
|
* This is an experimental API. Its behavior may change in the future.
|
|
138
137
|
*
|
|
@@ -152,12 +151,12 @@ const scan = async (rawInputOptions, rawOutputOptions = {}) => {
|
|
|
152
151
|
validateOption("input", rawInputOptions);
|
|
153
152
|
validateOption("output", rawOutputOptions);
|
|
154
153
|
const ret = await createBundlerOptions(await PluginDriver.callOptionsHook(rawInputOptions), rawOutputOptions, false);
|
|
155
|
-
const bundler = new import_binding
|
|
156
|
-
if (RolldownBuild.asyncRuntimeShutdown) (0, import_binding
|
|
154
|
+
const bundler = new import_binding.BindingBundler();
|
|
155
|
+
if (RolldownBuild.asyncRuntimeShutdown) (0, import_binding.startAsyncRuntime)();
|
|
157
156
|
async function cleanup() {
|
|
158
157
|
await bundler.close();
|
|
159
158
|
await ret.stopWorkers?.();
|
|
160
|
-
(0, import_binding
|
|
159
|
+
(0, import_binding.shutdownAsyncRuntime)();
|
|
161
160
|
RolldownBuild.asyncRuntimeShutdown = true;
|
|
162
161
|
}
|
|
163
162
|
let cleanupPromise = Promise.resolve();
|
|
@@ -243,7 +242,7 @@ function viteManifestPlugin(config) {
|
|
|
243
242
|
|
|
244
243
|
//#endregion
|
|
245
244
|
//#region src/experimental-index.ts
|
|
246
|
-
|
|
245
|
+
const memfs = void 0;
|
|
247
246
|
|
|
248
247
|
//#endregion
|
|
249
248
|
var BindingRebuildStrategy = import_binding.BindingRebuildStrategy;
|
|
@@ -256,4 +255,4 @@ var minifySync = import_binding.minifySync;
|
|
|
256
255
|
var moduleRunnerTransform = import_binding.moduleRunnerTransform;
|
|
257
256
|
var transform = import_binding.transform;
|
|
258
257
|
var transformSync = import_binding.transformSync;
|
|
259
|
-
export { BindingRebuildStrategy, DevEngine, ResolverFactory, createTokioRuntime, defineParallelPlugin, dev, viteDynamicImportVarsPlugin as dynamicImportVarsPlugin, viteDynamicImportVarsPlugin, freeExternalMemory, viteImportGlobPlugin as importGlobPlugin, viteImportGlobPlugin, isolatedDeclaration, isolatedDeclarationPlugin, isolatedDeclarationSync, minify, minifySync, moduleRunnerTransform, parse, parseSync, scan, transform, transformSync, viteAliasPlugin, viteAssetImportMetaUrlPlugin, viteAssetPlugin, viteBuildImportAnalysisPlugin, viteCSSPlugin, viteCSSPostPlugin, viteHtmlInlineProxyPlugin, viteHtmlPlugin, viteJsonPlugin, viteLoadFallbackPlugin, viteManifestPlugin, viteModulePreloadPolyfillPlugin, viteReactRefreshWrapperPlugin, viteReporterPlugin, viteResolvePlugin, viteTransformPlugin, viteWasmFallbackPlugin, viteWasmHelperPlugin, viteWebWorkerPostPlugin };
|
|
258
|
+
export { BindingRebuildStrategy, DevEngine, ResolverFactory, createTokioRuntime, defineParallelPlugin, dev, viteDynamicImportVarsPlugin as dynamicImportVarsPlugin, viteDynamicImportVarsPlugin, freeExternalMemory, viteImportGlobPlugin as importGlobPlugin, viteImportGlobPlugin, isolatedDeclaration, isolatedDeclarationPlugin, isolatedDeclarationSync, memfs, minify, minifySync, moduleRunnerTransform, parse, parseSync, scan, transform, transformSync, viteAliasPlugin, viteAssetImportMetaUrlPlugin, viteAssetPlugin, viteBuildImportAnalysisPlugin, viteCSSPlugin, viteCSSPostPlugin, viteHtmlInlineProxyPlugin, viteHtmlPlugin, viteJsonPlugin, viteLoadFallbackPlugin, viteManifestPlugin, viteModulePreloadPolyfillPlugin, viteReactRefreshWrapperPlugin, viteReporterPlugin, viteResolvePlugin, viteTransformPlugin, viteWasmFallbackPlugin, viteWasmHelperPlugin, viteWebWorkerPostPlugin };
|
package/dist/filter-index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "./shared/
|
|
1
|
+
import "./shared/binding-r9j8jqRV.mjs";
|
|
2
|
+
import { k as withFilter } from "./shared/define-config-MdVaFcie.mjs";
|
|
3
3
|
import { and, code, exclude, id, include, moduleType, not, or, queries, query } from "@rolldown/pluginutils";
|
|
4
4
|
export { and, code, exclude, id, include, moduleType, not, or, queries, query, withFilter };
|
package/dist/filter-index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as isPromiseLike, t as arraify } from "./shared/misc-
|
|
1
|
+
import { n as isPromiseLike, t as arraify } from "./shared/misc-DpjTMcQQ.mjs";
|
|
2
2
|
import { and, code, exclude, id, include, moduleType, not, or, queries, query } from "@rolldown/pluginutils";
|
|
3
3
|
|
|
4
4
|
//#region src/plugin/with-filter.ts
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { a as RollupLog } from "./shared/logging-BpAvp7KV.mjs";
|
|
2
|
+
|
|
3
|
+
//#region src/get-log-filter.d.ts
|
|
4
|
+
type GetLogFilter = (filters: string[]) => (log: RollupLog) => boolean;
|
|
5
|
+
declare const getLogFilter: GetLogFilter;
|
|
6
|
+
//#endregion
|
|
7
|
+
export { GetLogFilter, type RollupLog, getLogFilter as default };
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
//#region src/get-log-filter.ts
|
|
2
|
+
const getLogFilter = (filters) => {
|
|
3
|
+
if (filters.length === 0) return () => true;
|
|
4
|
+
const normalizedFilters = filters.map((filter) => filter.split("&").map((subFilter) => {
|
|
5
|
+
const inverted = subFilter.startsWith("!");
|
|
6
|
+
if (inverted) subFilter = subFilter.slice(1);
|
|
7
|
+
const [key, ...value] = subFilter.split(":");
|
|
8
|
+
return {
|
|
9
|
+
inverted,
|
|
10
|
+
key: key.split("."),
|
|
11
|
+
parts: value.join(":").split("*")
|
|
12
|
+
};
|
|
13
|
+
}));
|
|
14
|
+
return (log) => {
|
|
15
|
+
nextIntersectedFilter: for (const intersectedFilters of normalizedFilters) {
|
|
16
|
+
for (const { inverted, key, parts } of intersectedFilters) {
|
|
17
|
+
const isFilterSatisfied = testFilter(log, key, parts);
|
|
18
|
+
if (inverted ? isFilterSatisfied : !isFilterSatisfied) continue nextIntersectedFilter;
|
|
19
|
+
}
|
|
20
|
+
return true;
|
|
21
|
+
}
|
|
22
|
+
return false;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
const testFilter = (log, key, parts) => {
|
|
26
|
+
let rawValue = log;
|
|
27
|
+
for (let index = 0; index < key.length; index++) {
|
|
28
|
+
if (!rawValue) return false;
|
|
29
|
+
const part = key[index];
|
|
30
|
+
if (!(part in rawValue)) return false;
|
|
31
|
+
rawValue = rawValue[part];
|
|
32
|
+
}
|
|
33
|
+
let value = typeof rawValue === "object" ? JSON.stringify(rawValue) : String(rawValue);
|
|
34
|
+
if (parts.length === 1) return value === parts[0];
|
|
35
|
+
if (!value.startsWith(parts[0])) return false;
|
|
36
|
+
const lastPartIndex = parts.length - 1;
|
|
37
|
+
for (let index = 1; index < lastPartIndex; index++) {
|
|
38
|
+
const part = parts[index];
|
|
39
|
+
const position = value.indexOf(part);
|
|
40
|
+
if (position === -1) return false;
|
|
41
|
+
value = value.slice(position + part.length);
|
|
42
|
+
}
|
|
43
|
+
return value.endsWith(parts[lastPartIndex]);
|
|
44
|
+
};
|
|
45
|
+
var get_log_filter_default = getLogFilter;
|
|
46
|
+
|
|
47
|
+
//#endregion
|
|
48
|
+
export { get_log_filter_default as default };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { V as PreRenderedChunk, s as BindingMagicString } from "./shared/binding-
|
|
1
|
+
import { a as RollupLog, i as RollupError, n as LogLevelOption, o as RollupLogWithString, r as LogOrStringHandler, t as LogLevel } from "./shared/logging-BpAvp7KV.mjs";
|
|
2
|
+
import { V as PreRenderedChunk, s as BindingMagicString } from "./shared/binding-r9j8jqRV.mjs";
|
|
3
|
+
import { $ as RolldownFsModule, At as RolldownOutput, B as EmittedPrebuiltChunk, C as ResolveIdResult, D as SourceDescription, Dt as OutputChunk, E as RolldownPluginOption, Et as OutputAsset, F as OutputBundle, G as MinimalPluginContext, H as PluginContext, I as TreeshakingOptions, J as HookFilter, K as PluginContextMeta, L as TransformPluginContext, M as ExistingRawSourceMap, N as SourceMapInput, Nt as ModuleInfo, O as TransformResult, Ot as RenderedChunk, P as RolldownOptionsFunction, Pt as SourcemapIgnoreListOption, Q as RolldownFileStats, R as EmittedAsset, S as ResolveIdExtraOptions, St as PreRenderedAsset, T as RolldownPlugin, U as DefineParallelPluginResult, V as GetModuleInfo, X as BufferEncoding, Y as ModuleTypeFilter, Z as RolldownDirectoryEntry, _ as ModuleType, _t as GeneratedCodePreset, a as InputOption, at as watch, b as PartialResolvedId, bt as ModuleFormat, c as OptimizationOptions, ct as WatchOptions, d as CustomPluginOptions, dt as BuildOptions, et as InternalModuleFormat, f as FunctionPluginHooks, ft as build, g as ModuleOptions, gt as GeneratedCodeOptions, h as LoadResult, ht as ChunkingContext, i as ExternalOption, it as WarningHandlerWithDefault, j as VERSION, jt as SourceMap, kt as RenderedModule, l as WatcherOptions, lt as rolldown, m as ImportKind, mt as ChunkFileNamesFunction, n as ConfigExport, nt as NormalizedInputOptions, o as InputOptions, ot as RolldownWatcher, p as HookFilterExtension, pt as AddonFunction, q as GeneralHookFilter, r as RolldownOptions, rt as LoggingFunction, s as ModuleTypes, st as RolldownWatcherEvent, t as defineConfig, tt as NormalizedOutputOptions, u as AsyncPluginHooks, ut as RolldownBuild, v as ObjectHook, vt as GlobalsFunction, w as ResolvedId, wt as PartialNull, x as Plugin, xt as OutputOptions, y as ParallelPluginHooks, yt as MinifyOptions, z as EmittedFile } from "./shared/define-config-MdVaFcie.mjs";
|
|
3
4
|
export { AddonFunction, AsyncPluginHooks, BindingMagicString, BufferEncoding, BuildOptions, ChunkFileNamesFunction, ChunkingContext, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, EmittedPrebuiltChunk, 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,17 +1,17 @@
|
|
|
1
|
-
import { t as require_binding } from "./shared/binding-
|
|
2
|
-
import { n as onExit, t as watch } from "./shared/watch-
|
|
3
|
-
import { y as VERSION } from "./shared/normalize-string-or-regex-
|
|
4
|
-
import "./shared/rolldown-build-
|
|
5
|
-
import "./shared/bindingify-input-options-
|
|
6
|
-
import "./shared/parse-ast-index-
|
|
7
|
-
import { t as rolldown } from "./shared/rolldown-
|
|
8
|
-
import { t as defineConfig } from "./shared/define-config-
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./shared/binding-DMnPPQ90.mjs";
|
|
2
|
+
import { n as onExit, t as watch } from "./shared/watch-CKam-d6K.mjs";
|
|
3
|
+
import { y as VERSION } from "./shared/normalize-string-or-regex-B4d0IHth.mjs";
|
|
4
|
+
import "./shared/rolldown-build-CNW2eye_.mjs";
|
|
5
|
+
import "./shared/bindingify-input-options-A-rLIOKA.mjs";
|
|
6
|
+
import "./shared/parse-ast-index-CoZSRGeP.mjs";
|
|
7
|
+
import { t as rolldown } from "./shared/rolldown-BTFK71hw.mjs";
|
|
8
|
+
import { t as defineConfig } from "./shared/define-config-BF4P-Pum.mjs";
|
|
9
9
|
import { isMainThread } from "node:worker_threads";
|
|
10
10
|
|
|
11
11
|
//#region src/setup.ts
|
|
12
|
-
var import_binding
|
|
12
|
+
var import_binding = /* @__PURE__ */ __toESM(require_binding(), 1);
|
|
13
13
|
if (isMainThread) {
|
|
14
|
-
const subscriberGuard = (0, import_binding
|
|
14
|
+
const subscriberGuard = (0, import_binding.initTraceSubscriber)();
|
|
15
15
|
onExit(() => {
|
|
16
16
|
subscriberGuard?.close();
|
|
17
17
|
});
|
|
@@ -33,10 +33,6 @@ async function build(options) {
|
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
35
|
|
|
36
|
-
//#endregion
|
|
37
|
-
//#region src/index.ts
|
|
38
|
-
var import_binding = require_binding();
|
|
39
|
-
|
|
40
36
|
//#endregion
|
|
41
37
|
var BindingMagicString = import_binding.BindingMagicString;
|
|
42
38
|
export { BindingMagicString, VERSION, build, defineConfig, rolldown, watch };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { t as require_binding } from "./shared/binding-
|
|
2
|
-
import "./shared/normalize-string-or-regex-
|
|
3
|
-
import { n as PluginContextData, r as bindingifyPlugin } from "./shared/bindingify-input-options-
|
|
4
|
-
import "./shared/parse-ast-index-
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./shared/binding-DMnPPQ90.mjs";
|
|
2
|
+
import "./shared/normalize-string-or-regex-B4d0IHth.mjs";
|
|
3
|
+
import { n as PluginContextData, r as bindingifyPlugin } from "./shared/bindingify-input-options-A-rLIOKA.mjs";
|
|
4
|
+
import "./shared/parse-ast-index-CoZSRGeP.mjs";
|
|
5
5
|
import { parentPort, workerData } from "node:worker_threads";
|
|
6
6
|
|
|
7
7
|
//#region src/parallel-plugin-worker.ts
|
|
8
|
-
var import_binding = require_binding();
|
|
8
|
+
var import_binding = /* @__PURE__ */ __toESM(require_binding(), 1);
|
|
9
9
|
const { registryId, pluginInfos, threadNumber } = workerData;
|
|
10
10
|
(async () => {
|
|
11
11
|
try {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "./shared/
|
|
1
|
+
import "./shared/binding-r9j8jqRV.mjs";
|
|
2
|
+
import { Ct as MaybePromise, x as Plugin } from "./shared/define-config-MdVaFcie.mjs";
|
|
3
3
|
|
|
4
4
|
//#region src/plugin/parallel-plugin-implementation.d.ts
|
|
5
5
|
type ParallelPluginImplementation = Plugin;
|
package/dist/parse-ast-index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "./shared/binding-
|
|
2
|
-
import { n as parseAstAsync, t as parseAst } from "./shared/parse-ast-index-
|
|
1
|
+
import "./shared/binding-DMnPPQ90.mjs";
|
|
2
|
+
import { n as parseAstAsync, t as parseAst } from "./shared/parse-ast-index-CoZSRGeP.mjs";
|
|
3
3
|
|
|
4
4
|
export { parseAst, parseAstAsync };
|
package/dist/plugins-index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { t as esmExternalRequirePlugin } from "./shared/constructors-
|
|
1
|
+
import { u as BindingReplacePluginConfig } from "./shared/binding-r9j8jqRV.mjs";
|
|
2
|
+
import { A as BuiltinPlugin } from "./shared/define-config-MdVaFcie.mjs";
|
|
3
|
+
import { t as esmExternalRequirePlugin } from "./shared/constructors-DO8UjlE5.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/builtin-plugin/replace-plugin.d.ts
|
|
6
6
|
|
package/dist/plugins-index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "./shared/binding-
|
|
2
|
-
import { n as BuiltinPlugin, s as makeBuiltinPluginCallable } from "./shared/normalize-string-or-regex-
|
|
3
|
-
import { t as esmExternalRequirePlugin } from "./shared/constructors-
|
|
1
|
+
import "./shared/binding-DMnPPQ90.mjs";
|
|
2
|
+
import { n as BuiltinPlugin, s as makeBuiltinPluginCallable } from "./shared/normalize-string-or-regex-B4d0IHth.mjs";
|
|
3
|
+
import { t as esmExternalRequirePlugin } from "./shared/constructors-BGI2r6Tk.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/builtin-plugin/replace-plugin.ts
|
|
6
6
|
/**
|