@rollipop/rolldown 1.0.0-rc.4 → 1.0.0-rc.6
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 +768 -185
- package/dist/config.d.mts +1 -2
- package/dist/config.mjs +2 -8
- package/dist/experimental-index.d.mts +13 -7
- package/dist/experimental-index.mjs +27 -13
- package/dist/filter-index.d.mts +1 -2
- package/dist/index.d.mts +3 -3
- package/dist/index.mjs +5 -10
- package/dist/parallel-plugin-worker.mjs +2 -5
- package/dist/parallel-plugin.d.mts +1 -2
- package/dist/parse-ast-index.d.mts +1 -1
- package/dist/parse-ast-index.mjs +1 -2
- package/dist/plugins-index.d.mts +3 -3
- package/dist/plugins-index.mjs +2 -3
- package/dist/shared/{binding-BohGL_65.d.mts → binding-BEVObikP.d.mts} +40 -17
- package/dist/shared/{binding-BuW0Fhs2.mjs → binding-BaD00V3B.mjs} +26 -26
- package/dist/shared/{bindingify-input-options-o_7NioSs.mjs → bindingify-input-options-KbcygofY.mjs} +52 -13
- package/dist/shared/{constructors-Dg8A45sy.d.mts → constructors-C0o3D5kM.d.mts} +7 -3
- package/dist/shared/{constructors-FqGyV5fj.mjs → constructors-DoVEGpfv.mjs} +8 -2
- package/dist/shared/{define-config-BvszQ-i2.d.mts → define-config-Dcf0-wDh.d.mts} +70 -12
- package/dist/shared/{error-BjNWBTlf.mjs → error-DMdvzIth.mjs} +1 -1
- package/dist/shared/{load-config-2dmAH96P.mjs → load-config-Cl0c9rzt.mjs} +1 -1
- package/dist/shared/{normalize-string-or-regex-BU5HSJy4.mjs → normalize-string-or-regex-C438JWX3.mjs} +20 -12
- package/dist/shared/{parse-Bt4kI3ey.mjs → parse-B_pfrOxH.mjs} +2 -2
- package/dist/shared/{transform-Cbhgjik0.mjs → resolve-tsconfig-C4k6MVJe.mjs} +28 -5
- package/dist/shared/{rolldown-build-tLuGZc7p.mjs → rolldown-build-CLB7U-T8.mjs} +20 -12
- package/dist/shared/{rolldown-B4lV-glW.mjs → rolldown-cb9tsyMG.mjs} +1 -1
- package/dist/shared/{transform-BoJxrM-e.d.mts → transform-CHWi6pVJ.d.mts} +19 -2
- package/dist/shared/{watch-hs9ntURJ.mjs → watch-dXreyeuN.mjs} +4 -4
- package/dist/utils-index.d.mts +3 -3
- package/dist/utils-index.mjs +5 -8
- package/package.json +19 -18
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as RolldownLog, i as RolldownError, n as LogLevelOption, o as RolldownLogWithString, r as LogOrStringHandler, t as LogLevel } from "./logging-C6h4g8dA.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { B as ParserOptions, F as JsxOptions, G as TransformOptions$1, I as MinifyOptions$1, M as ExternalMemoryStatus, V as PreRenderedChunk, _ as BindingTransformHookExtraArgs, c as BindingHookResolveIdExtraArgs, d as BindingPluginContextResolveOptions, j as BindingWatcherBundler, p as BindingRenderedChunk, t as BindingBuiltinPluginName, u as BindingMagicString } from "./binding-BEVObikP.mjs";
|
|
3
3
|
import { TopLevelFilterExpression } from "@rollipop/rolldown-pluginutils";
|
|
4
4
|
import { Program } from "@oxc-project/types";
|
|
5
5
|
|
|
@@ -465,6 +465,16 @@ interface OutputOptions {
|
|
|
465
465
|
*/
|
|
466
466
|
sourcemapPathTransform?: SourcemapPathTransformOption;
|
|
467
467
|
/**
|
|
468
|
+
* Whether to exclude the original source code from sourcemaps.
|
|
469
|
+
*
|
|
470
|
+
* When `true`, the `sourcesContent` field is omitted from the generated sourcemap,
|
|
471
|
+
* reducing the sourcemap file size. The sourcemap will still contain source file paths
|
|
472
|
+
* and mappings, so debugging works if the original files are available.
|
|
473
|
+
*
|
|
474
|
+
* @default false
|
|
475
|
+
*/
|
|
476
|
+
sourcemapExcludeSources?: boolean;
|
|
477
|
+
/**
|
|
468
478
|
* A string to prepend to the bundle before {@linkcode Plugin.renderChunk | renderChunk} hook.
|
|
469
479
|
*
|
|
470
480
|
* See {@linkcode intro | output.intro}, {@linkcode postBanner | output.postBanner} as well.
|
|
@@ -595,11 +605,11 @@ interface OutputOptions {
|
|
|
595
605
|
* Rolldown uses Oxc Minifier under the hood. See Oxc's [minification documentation](https://oxc.rs/docs/guide/usage/minifier#features) for more details.
|
|
596
606
|
*
|
|
597
607
|
* - `true`: Enable full minification including code compression and dead code elimination
|
|
598
|
-
* - `false`: Disable minification
|
|
599
|
-
* - `'dce-only'`: Only perform dead code elimination without code compression
|
|
608
|
+
* - `false`: Disable minification
|
|
609
|
+
* - `'dce-only'`: Only perform dead code elimination without code compression (default)
|
|
600
610
|
* - `MinifyOptions`: Fine-grained control over minification settings
|
|
601
611
|
*
|
|
602
|
-
* @default
|
|
612
|
+
* @default 'dce-only'
|
|
603
613
|
*/
|
|
604
614
|
minify?: boolean | "dce-only" | MinifyOptions;
|
|
605
615
|
/**
|
|
@@ -949,6 +959,11 @@ interface OutputOptions {
|
|
|
949
959
|
* @default []
|
|
950
960
|
*/
|
|
951
961
|
globalIdentifiers?: string[];
|
|
962
|
+
/**
|
|
963
|
+
* Enable persistent transform cache to disk.
|
|
964
|
+
* @default false
|
|
965
|
+
*/
|
|
966
|
+
persistentCache?: boolean;
|
|
952
967
|
}
|
|
953
968
|
type CodeSplittingGroup = {
|
|
954
969
|
/**
|
|
@@ -1404,6 +1419,25 @@ interface RolldownWatcher {
|
|
|
1404
1419
|
*/
|
|
1405
1420
|
declare function watch(input: WatchOptions | WatchOptions[]): RolldownWatcher;
|
|
1406
1421
|
//#endregion
|
|
1422
|
+
//#region src/binding-magic-string.d.ts
|
|
1423
|
+
interface RolldownMagicString extends BindingMagicString {
|
|
1424
|
+
readonly isRolldownMagicString: true;
|
|
1425
|
+
/** Accepts a string or RegExp pattern. RegExp supports `$&`, `$$`, and `$N` substitutions. */
|
|
1426
|
+
replace(from: string | RegExp, to: string): this;
|
|
1427
|
+
/** Accepts a string or RegExp pattern. RegExp must have the global (`g`) flag. */
|
|
1428
|
+
replaceAll(from: string | RegExp, to: string): this;
|
|
1429
|
+
}
|
|
1430
|
+
type RolldownMagicStringConstructor = Omit<typeof BindingMagicString, "prototype"> & {
|
|
1431
|
+
new (...args: ConstructorParameters<typeof BindingMagicString>): RolldownMagicString;
|
|
1432
|
+
prototype: RolldownMagicString;
|
|
1433
|
+
};
|
|
1434
|
+
/**
|
|
1435
|
+
* A native MagicString implementation powered by Rust.
|
|
1436
|
+
*
|
|
1437
|
+
* @experimental
|
|
1438
|
+
*/
|
|
1439
|
+
declare const RolldownMagicString: RolldownMagicStringConstructor;
|
|
1440
|
+
//#endregion
|
|
1407
1441
|
//#region src/log/log-handler.d.ts
|
|
1408
1442
|
type LoggingFunction = (log: RolldownLog | string | (() => RolldownLog | string)) => void;
|
|
1409
1443
|
type LoggingFunctionWithPosition = (log: RolldownLog | string | (() => RolldownLog | string), pos?: number | {
|
|
@@ -1745,6 +1779,8 @@ interface NormalizedOutputOptions {
|
|
|
1745
1779
|
hashCharacters: "base64" | "base36" | "hex";
|
|
1746
1780
|
/** @see {@linkcode OutputOptions.sourcemapDebugIds | sourcemapDebugIds} */
|
|
1747
1781
|
sourcemapDebugIds: boolean;
|
|
1782
|
+
/** @see {@linkcode OutputOptions.sourcemapExcludeSources | sourcemapExcludeSources} */
|
|
1783
|
+
sourcemapExcludeSources: boolean;
|
|
1748
1784
|
/** @see {@linkcode OutputOptions.sourcemapIgnoreList | sourcemapIgnoreList} */
|
|
1749
1785
|
sourcemapIgnoreList: boolean | SourcemapIgnoreListOption | StringOrRegExp | undefined;
|
|
1750
1786
|
/** @see {@linkcode OutputOptions.sourcemapPathTransform | sourcemapPathTransform} */
|
|
@@ -1929,8 +1965,6 @@ interface PluginContextMeta {
|
|
|
1929
1965
|
}
|
|
1930
1966
|
/** @category Plugin APIs */
|
|
1931
1967
|
interface MinimalPluginContext {
|
|
1932
|
-
/** @hidden */
|
|
1933
|
-
readonly pluginName: string;
|
|
1934
1968
|
/**
|
|
1935
1969
|
* Similar to {@linkcode warn | this.warn}, except that it will also abort
|
|
1936
1970
|
* the bundling process with an error.
|
|
@@ -2646,7 +2680,7 @@ type ResolveIdResult = string | NullValue | false | PartialResolvedId;
|
|
|
2646
2680
|
type LoadResult = NullValue | string | SourceDescription;
|
|
2647
2681
|
/** @inline @category Plugin APIs */
|
|
2648
2682
|
type TransformResult = NullValue | string | (Omit<SourceDescription, "code"> & {
|
|
2649
|
-
code?: string |
|
|
2683
|
+
code?: string | RolldownMagicString;
|
|
2650
2684
|
});
|
|
2651
2685
|
type RenderedChunkMeta = {
|
|
2652
2686
|
/**
|
|
@@ -2659,7 +2693,7 @@ type RenderedChunkMeta = {
|
|
|
2659
2693
|
* Use this to perform string transformations with automatic source map support.
|
|
2660
2694
|
* This is only available when `experimental.nativeMagicString` is enabled.
|
|
2661
2695
|
*/
|
|
2662
|
-
magicString?:
|
|
2696
|
+
magicString?: RolldownMagicString;
|
|
2663
2697
|
};
|
|
2664
2698
|
/** @category Plugin APIs */
|
|
2665
2699
|
interface FunctionPluginHooks {
|
|
@@ -2766,7 +2800,7 @@ interface FunctionPluginHooks {
|
|
|
2766
2800
|
*/
|
|
2767
2801
|
[DEFINED_HOOK_NAMES.transform]: (this: TransformPluginContext, code: string, id: string, meta: BindingTransformHookExtraArgs & {
|
|
2768
2802
|
moduleType: ModuleType;
|
|
2769
|
-
magicString?:
|
|
2803
|
+
magicString?: RolldownMagicString;
|
|
2770
2804
|
ast?: Program;
|
|
2771
2805
|
}) => TransformResult;
|
|
2772
2806
|
/**
|
|
@@ -2819,8 +2853,8 @@ interface FunctionPluginHooks {
|
|
|
2819
2853
|
*
|
|
2820
2854
|
* @group Output Generation Hooks
|
|
2821
2855
|
*/
|
|
2822
|
-
[DEFINED_HOOK_NAMES.renderChunk]: (this: PluginContext, code: string, chunk: RenderedChunk, outputOptions: NormalizedOutputOptions, meta: RenderedChunkMeta) => NullValue | string |
|
|
2823
|
-
code: string |
|
|
2856
|
+
[DEFINED_HOOK_NAMES.renderChunk]: (this: PluginContext, code: string, chunk: RenderedChunk, outputOptions: NormalizedOutputOptions, meta: RenderedChunkMeta) => NullValue | string | RolldownMagicString | {
|
|
2857
|
+
code: string | RolldownMagicString;
|
|
2824
2858
|
map?: SourceMapInput;
|
|
2825
2859
|
};
|
|
2826
2860
|
/**
|
|
@@ -3051,6 +3085,24 @@ interface WatcherFileWatcherOptions {
|
|
|
3051
3085
|
* @default false
|
|
3052
3086
|
*/
|
|
3053
3087
|
compareContentsForPolling?: boolean;
|
|
3088
|
+
/**
|
|
3089
|
+
* Whether to use debounced event delivery at the filesystem level.
|
|
3090
|
+
* This coalesces rapid filesystem events before they reach the build coordinator.
|
|
3091
|
+
* @default false
|
|
3092
|
+
*/
|
|
3093
|
+
useDebounce?: boolean;
|
|
3094
|
+
/**
|
|
3095
|
+
* Debounce delay in milliseconds for fs-level debounced watchers.
|
|
3096
|
+
* Only used when {@linkcode useDebounce} is `true`.
|
|
3097
|
+
* @default 10
|
|
3098
|
+
*/
|
|
3099
|
+
debounceDelay?: number;
|
|
3100
|
+
/**
|
|
3101
|
+
* Tick rate in milliseconds for the debouncer's internal polling.
|
|
3102
|
+
* Only used when {@linkcode useDebounce} is `true`.
|
|
3103
|
+
* When undefined, auto-selects 1/4 of debounceDelay.
|
|
3104
|
+
*/
|
|
3105
|
+
debounceTickRate?: number;
|
|
3054
3106
|
}
|
|
3055
3107
|
interface WatcherOptions {
|
|
3056
3108
|
/**
|
|
@@ -3655,6 +3707,8 @@ interface InputOptions {
|
|
|
3655
3707
|
*
|
|
3656
3708
|
* These options only take effect when running with the [`--watch`](/apis/cli#w-watch) flag, or using {@linkcode watch | watch()} API.
|
|
3657
3709
|
*
|
|
3710
|
+
*
|
|
3711
|
+
*
|
|
3658
3712
|
* @experimental
|
|
3659
3713
|
*/
|
|
3660
3714
|
watch?: WatcherOptions | false;
|
|
@@ -3712,6 +3766,10 @@ interface InputOptions {
|
|
|
3712
3766
|
* @default true
|
|
3713
3767
|
*/
|
|
3714
3768
|
tsconfig?: boolean | string;
|
|
3769
|
+
/**
|
|
3770
|
+
* Unique identifier for build task.
|
|
3771
|
+
*/
|
|
3772
|
+
id?: string;
|
|
3715
3773
|
}
|
|
3716
3774
|
//#endregion
|
|
3717
3775
|
//#region src/types/rolldown-options.d.ts
|
|
@@ -3749,4 +3807,4 @@ declare function defineConfig(config: RolldownOptions[]): RolldownOptions[];
|
|
|
3749
3807
|
declare function defineConfig(config: RolldownOptionsFunction): RolldownOptionsFunction;
|
|
3750
3808
|
declare function defineConfig(config: ConfigExport): ConfigExport;
|
|
3751
3809
|
//#endregion
|
|
3752
|
-
export { GeneralHookFilter as $, SourceDescription as A,
|
|
3810
|
+
export { GeneralHookFilter as $, SourceDescription as A, CodeSplittingOptions as At, TreeshakingOptions as B, PartialNull as Bt, PartialResolvedId as C, AddonFunction as Ct, ResolvedId as D, ChunkingContext as Dt, ResolveIdResult as E, ChunkFileNamesFunction as Et, VERSION as F, MinifyOptions as Ft, EmittedPrebuiltChunk as G, RenderedModule as Gt, EmittedAsset as H, OutputAsset as Ht, BundleError as I, ModuleFormat as It, PluginContextResolveOptions as J, freeExternalMemory as Jt, GetModuleInfo as K, RolldownOutput as Kt, ExistingRawSourceMap as L, OutputOptions as Lt, withFilter as M, GeneratedCodeOptions as Mt, BuiltinPlugin as N, GeneratedCodePreset as Nt, RolldownPlugin as O, CodeSplittingGroup as Ot, RUNTIME_MODULE_ID as P, GlobalsFunction as Pt, PluginContextMeta as Q, SourceMapInput as R, PreRenderedAsset as Rt, ParallelPluginHooks as S, build as St, ResolveIdExtraOptions as T, AdvancedChunksOptions as Tt, EmittedChunk as U, OutputChunk as Ut, TransformPluginContext as V, StringOrRegExp as Vt, EmittedFile as W, RenderedChunk as Wt, defineParallelPlugin as X, SourcemapIgnoreListOption as Xt, DefineParallelPluginResult as Y, ModuleInfo as Yt, MinimalPluginContext as Z, ImportKind as _, RolldownWatcherWatcherEventMap as _t, ExternalOption as a, RolldownFsModule as at, ModuleType as b, RolldownBuild as bt, InputOptions as c, NormalizedInputOptions as ct, WatcherFileWatcherOptions as d, LoggingFunction as dt, HookFilter as et, WatcherOptions as f, WarningHandlerWithDefault as ft, HookFilterExtension as g, RolldownWatcherEvent as gt, FunctionPluginHooks as h, RolldownWatcher as ht, RolldownOptions as i, RolldownFileStats as it, TransformResult as j, CommentsOptions as jt, RolldownPluginOption as k, CodeSplittingNameFunction as kt, ModuleTypes as l, TransformOptions as lt, CustomPluginOptions as m, watch as mt, RolldownOptionsFunction as n, BufferEncoding as nt, ExternalOptionFunction as o, InternalModuleFormat as ot, AsyncPluginHooks as p, RolldownMagicString as pt, PluginContext as q, SourceMap as qt, defineConfig as r, RolldownDirectoryEntry as rt, InputOption as s, NormalizedOutputOptions as st, ConfigExport as t, ModuleTypeFilter as tt, OptimizationOptions as u, ChecksOptions as ut, LoadResult as v, WatchOptions as vt, Plugin as w, AdvancedChunksGroup as wt, ObjectHook as x, BuildOptions as xt, ModuleOptions as y, rolldown as yt, OutputBundle as z, MaybePromise as zt };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as __toESM, t as require_binding } from "./binding-
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./binding-BaD00V3B.mjs";
|
|
2
2
|
import { c as logPluginError, n as error } from "./logs-D80CXhvg.mjs";
|
|
3
3
|
//#region src/builtin-plugin/utils.ts
|
|
4
4
|
var import_binding = /* @__PURE__ */ __toESM(require_binding(), 1);
|
|
@@ -13,17 +13,25 @@ var BuiltinPlugin = class {
|
|
|
13
13
|
function makeBuiltinPluginCallable(plugin) {
|
|
14
14
|
let callablePlugin = new import_binding.BindingCallableBuiltinPlugin(bindingifyBuiltInPlugin(plugin));
|
|
15
15
|
const wrappedPlugin = plugin;
|
|
16
|
-
for (const key in callablePlugin)
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
16
|
+
for (const key in callablePlugin) {
|
|
17
|
+
const wrappedHook = async function(...args) {
|
|
18
|
+
try {
|
|
19
|
+
return await callablePlugin[key](...args);
|
|
20
|
+
} catch (e) {
|
|
21
|
+
if (e instanceof Error && !e.stack?.includes("at ")) Error.captureStackTrace(e, wrappedPlugin[key]);
|
|
22
|
+
return error(logPluginError(e, plugin.name, {
|
|
23
|
+
hook: key,
|
|
24
|
+
id: key === "transform" ? args[2] : void 0
|
|
25
|
+
}));
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
const order = callablePlugin.getOrder(key);
|
|
29
|
+
if (order == void 0) wrappedPlugin[key] = wrappedHook;
|
|
30
|
+
else wrappedPlugin[key] = {
|
|
31
|
+
handler: wrappedHook,
|
|
32
|
+
order
|
|
33
|
+
};
|
|
34
|
+
}
|
|
27
35
|
return wrappedPlugin;
|
|
28
36
|
}
|
|
29
37
|
function bindingifyBuiltInPlugin(plugin) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as __toESM, t as require_binding } from "./binding-
|
|
2
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./binding-BaD00V3B.mjs";
|
|
2
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.121.0/node_modules/oxc-parser/src-js/wrap.js
|
|
3
3
|
function wrap(result) {
|
|
4
4
|
let program, module, comments, errors;
|
|
5
5
|
return {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as __toESM, t as require_binding } from "./binding-
|
|
2
|
-
import { a as bindingifySourcemap, n as normalizeBindingError } from "./error-
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./binding-BaD00V3B.mjs";
|
|
2
|
+
import { a as bindingifySourcemap, n as normalizeBindingError } from "./error-DMdvzIth.mjs";
|
|
3
3
|
//#region src/utils/minify.ts
|
|
4
4
|
var import_binding = /* @__PURE__ */ __toESM(require_binding(), 1);
|
|
5
5
|
/**
|
|
@@ -36,6 +36,7 @@ function minifySync(filename, sourceText, options) {
|
|
|
36
36
|
}
|
|
37
37
|
//#endregion
|
|
38
38
|
//#region src/utils/transform.ts
|
|
39
|
+
const yarnPnp$1 = typeof process === "object" && !!process.versions?.pnp;
|
|
39
40
|
/**
|
|
40
41
|
* Transpile a JavaScript or TypeScript into a target ECMAScript version, asynchronously.
|
|
41
42
|
*
|
|
@@ -55,7 +56,7 @@ function minifySync(filename, sourceText, options) {
|
|
|
55
56
|
* @experimental
|
|
56
57
|
*/
|
|
57
58
|
async function transform(filename, sourceText, options, cache) {
|
|
58
|
-
const result = await (0, import_binding.enhancedTransform)(filename, sourceText, options, cache);
|
|
59
|
+
const result = await (0, import_binding.enhancedTransform)(filename, sourceText, options, cache, yarnPnp$1);
|
|
59
60
|
return {
|
|
60
61
|
...result,
|
|
61
62
|
errors: result.errors.map(normalizeBindingError),
|
|
@@ -79,7 +80,7 @@ async function transform(filename, sourceText, options, cache) {
|
|
|
79
80
|
* @experimental
|
|
80
81
|
*/
|
|
81
82
|
function transformSync(filename, sourceText, options, cache) {
|
|
82
|
-
const result = (0, import_binding.enhancedTransformSync)(filename, sourceText, options, cache);
|
|
83
|
+
const result = (0, import_binding.enhancedTransformSync)(filename, sourceText, options, cache, yarnPnp$1);
|
|
83
84
|
return {
|
|
84
85
|
...result,
|
|
85
86
|
errors: result.errors.map(normalizeBindingError),
|
|
@@ -87,4 +88,26 @@ function transformSync(filename, sourceText, options, cache) {
|
|
|
87
88
|
};
|
|
88
89
|
}
|
|
89
90
|
//#endregion
|
|
90
|
-
|
|
91
|
+
//#region src/utils/resolve-tsconfig.ts
|
|
92
|
+
const yarnPnp = typeof process === "object" && !!process.versions?.pnp;
|
|
93
|
+
/**
|
|
94
|
+
* Cache for tsconfig resolution to avoid redundant file system operations.
|
|
95
|
+
*
|
|
96
|
+
* The cache stores resolved tsconfig configurations keyed by their file paths.
|
|
97
|
+
* When transforming multiple files in the same project, tsconfig lookups are
|
|
98
|
+
* deduplicated, improving performance.
|
|
99
|
+
*
|
|
100
|
+
* @category Utilities
|
|
101
|
+
* @experimental
|
|
102
|
+
*/
|
|
103
|
+
var TsconfigCache = class extends import_binding.TsconfigCache {
|
|
104
|
+
constructor() {
|
|
105
|
+
super(yarnPnp);
|
|
106
|
+
}
|
|
107
|
+
};
|
|
108
|
+
/** @hidden This is only expected to be used by Vite */
|
|
109
|
+
function resolveTsconfig(filename, cache) {
|
|
110
|
+
return (0, import_binding.resolveTsconfig)(filename, cache, yarnPnp);
|
|
111
|
+
}
|
|
112
|
+
//#endregion
|
|
113
|
+
export { minify as a, transformSync as i, resolveTsconfig as n, minifySync as o, transform as r, TsconfigCache as t };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { n as __toESM, t as require_binding } from "./binding-
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./binding-BaD00V3B.mjs";
|
|
2
2
|
import { i as logInputHookInOutputPlugin, n as error } from "./logs-D80CXhvg.mjs";
|
|
3
|
-
import { n as BuiltinPlugin } from "./normalize-string-or-regex-
|
|
4
|
-
import {
|
|
3
|
+
import { n as BuiltinPlugin } from "./normalize-string-or-regex-C438JWX3.mjs";
|
|
4
|
+
import { c as __decorate, d as PlainObjectLike, f as MinimalPluginContextImpl, h as LOG_LEVEL_DEBUG, i as transformModuleInfo, l as transformAssetSource, m as normalizeLog, o as transformToRollupOutput, p as normalizeHook, s as transformRenderedChunk, t as bindingifyInputOptions, u as lazyProp, v as LOG_LEVEL_WARN, x as VERSION, y as logLevelPriority } from "./bindingify-input-options-KbcygofY.mjs";
|
|
5
5
|
import { i as unimplemented } from "./misc-DJYbNKZX.mjs";
|
|
6
|
-
import { i as unwrapBindingResult } from "./error-
|
|
6
|
+
import { i as unwrapBindingResult } from "./error-DMdvzIth.mjs";
|
|
7
7
|
import { Worker } from "node:worker_threads";
|
|
8
8
|
import path, { sep } from "node:path";
|
|
9
9
|
import { formatWithOptions, styleText } from "node:util";
|
|
@@ -211,7 +211,7 @@ function getSortedPlugins(hookName, plugins) {
|
|
|
211
211
|
];
|
|
212
212
|
}
|
|
213
213
|
//#endregion
|
|
214
|
-
//#region ../../node_modules/.pnpm/valibot@1.
|
|
214
|
+
//#region ../../node_modules/.pnpm/valibot@1.3.1_typescript@5.9.3/node_modules/valibot/dist/index.mjs
|
|
215
215
|
let store$4;
|
|
216
216
|
/**
|
|
217
217
|
* Returns the global configuration.
|
|
@@ -1512,7 +1512,7 @@ const TransformOptionsSchema = /* @__PURE__ */ object({
|
|
|
1512
1512
|
JsxOptionsSchema
|
|
1513
1513
|
])),
|
|
1514
1514
|
target: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ union([/* @__PURE__ */ string(), /* @__PURE__ */ array(/* @__PURE__ */ string())])), /* @__PURE__ */ description("The JavaScript target environment")),
|
|
1515
|
-
define: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ record(/* @__PURE__ */ string(), /* @__PURE__ */ string())), /* @__PURE__ */ description("Define global variables (syntax: key
|
|
1515
|
+
define: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ record(/* @__PURE__ */ string(), /* @__PURE__ */ string())), /* @__PURE__ */ description("Define global variables (syntax: key:value,key2:value2)")),
|
|
1516
1516
|
inject: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ record(/* @__PURE__ */ string(), /* @__PURE__ */ union([/* @__PURE__ */ string(), /* @__PURE__ */ tuple([/* @__PURE__ */ string(), /* @__PURE__ */ string()])]))), /* @__PURE__ */ description("Inject import statements on demand")),
|
|
1517
1517
|
dropLabels: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ array(/* @__PURE__ */ string())), /* @__PURE__ */ description("Remove labeled statements with these label names")),
|
|
1518
1518
|
plugins: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(TransformPluginsSchema), /* @__PURE__ */ description("Third-party plugins to use"))
|
|
@@ -1521,7 +1521,10 @@ isTypeTrue();
|
|
|
1521
1521
|
const WatcherFileWatcherOptionsSchema = /* @__PURE__ */ strictObject({
|
|
1522
1522
|
usePolling: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Use polling-based file watching instead of native OS events")),
|
|
1523
1523
|
pollInterval: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ number()), /* @__PURE__ */ description("Poll interval in milliseconds (only used when usePolling is true)")),
|
|
1524
|
-
compareContentsForPolling: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Compare file contents for poll-based watchers (only used when usePolling is true)"))
|
|
1524
|
+
compareContentsForPolling: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Compare file contents for poll-based watchers (only used when usePolling is true)")),
|
|
1525
|
+
useDebounce: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Use debounced event delivery at the filesystem level")),
|
|
1526
|
+
debounceDelay: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ number()), /* @__PURE__ */ description("Debounce delay in milliseconds (only used when useDebounce is true)")),
|
|
1527
|
+
debounceTickRate: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ number()), /* @__PURE__ */ description("Tick rate in milliseconds for debouncer (only used when useDebounce is true)"))
|
|
1525
1528
|
});
|
|
1526
1529
|
const WatcherOptionsSchema = /* @__PURE__ */ strictObject({
|
|
1527
1530
|
chokidar: /* @__PURE__ */ optional(/* @__PURE__ */ never(`The "watch.chokidar" option is deprecated, please use "watch.watcher" instead of it`)),
|
|
@@ -1707,7 +1710,8 @@ const InputOptionsSchema = /* @__PURE__ */ strictObject({
|
|
|
1707
1710
|
/* @__PURE__ */ literal(false)
|
|
1708
1711
|
]))),
|
|
1709
1712
|
context: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ string()), /* @__PURE__ */ description("The value of `this` at the top level of each module.")),
|
|
1710
|
-
tsconfig: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ union([/* @__PURE__ */ boolean(), /* @__PURE__ */ string()])), /* @__PURE__ */ description("Path to the tsconfig.json file."))
|
|
1713
|
+
tsconfig: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ union([/* @__PURE__ */ boolean(), /* @__PURE__ */ string()])), /* @__PURE__ */ description("Path to the tsconfig.json file.")),
|
|
1714
|
+
id: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ string()), /* @__PURE__ */ description("Unique identifier for build task"))
|
|
1711
1715
|
});
|
|
1712
1716
|
isTypeTrue();
|
|
1713
1717
|
const InputCliOverrideSchema = /* @__PURE__ */ strictObject({
|
|
@@ -1812,9 +1816,10 @@ const OutputOptionsSchema = /* @__PURE__ */ strictObject({
|
|
|
1812
1816
|
/* @__PURE__ */ boolean(),
|
|
1813
1817
|
/* @__PURE__ */ literal("inline"),
|
|
1814
1818
|
/* @__PURE__ */ literal("hidden")
|
|
1815
|
-
])), /* @__PURE__ */ description(`Generate sourcemap (\`-s inline\` for inline, or
|
|
1819
|
+
])), /* @__PURE__ */ description(`Generate sourcemap (\`-s inline\` for inline, or \`-s\` for \`.map\` file)`)),
|
|
1816
1820
|
sourcemapBaseUrl: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ string()), /* @__PURE__ */ description("Base URL used to prefix sourcemap paths")),
|
|
1817
1821
|
sourcemapDebugIds: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Inject sourcemap debug IDs")),
|
|
1822
|
+
sourcemapExcludeSources: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Exclude source content from sourcemaps")),
|
|
1818
1823
|
sourcemapIgnoreList: /* @__PURE__ */ optional(/* @__PURE__ */ union([
|
|
1819
1824
|
/* @__PURE__ */ boolean(),
|
|
1820
1825
|
/* @__PURE__ */ custom(() => true),
|
|
@@ -1839,7 +1844,7 @@ const OutputOptionsSchema = /* @__PURE__ */ strictObject({
|
|
|
1839
1844
|
MinifyOptionsSchema
|
|
1840
1845
|
])), /* @__PURE__ */ description("Minify the bundled file")),
|
|
1841
1846
|
name: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ string()), /* @__PURE__ */ description("Name for UMD / IIFE format outputs")),
|
|
1842
|
-
globals: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ union([/* @__PURE__ */ record(/* @__PURE__ */ string(), /* @__PURE__ */ string()), GlobalsFunctionSchema])), /* @__PURE__ */ description("Global variable of UMD / IIFE dependencies (syntax: `key
|
|
1847
|
+
globals: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ union([/* @__PURE__ */ record(/* @__PURE__ */ string(), /* @__PURE__ */ string()), GlobalsFunctionSchema])), /* @__PURE__ */ description("Global variable of UMD / IIFE dependencies (syntax: `key:value`)")),
|
|
1843
1848
|
paths: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ union([/* @__PURE__ */ record(/* @__PURE__ */ string(), /* @__PURE__ */ string()), PathsFunctionSchema])), /* @__PURE__ */ description("Maps external module IDs to paths")),
|
|
1844
1849
|
generatedCode: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ partial(GeneratedCodeOptionsSchema)), /* @__PURE__ */ description("Generated code options")),
|
|
1845
1850
|
externalLiveBindings: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("external live bindings")),
|
|
@@ -1866,6 +1871,7 @@ const OutputOptionsSchema = /* @__PURE__ */ strictObject({
|
|
|
1866
1871
|
keepNames: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Keep function and class names after bundling")),
|
|
1867
1872
|
strictExecutionOrder: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Lets modules be executed in the order they are declared.")),
|
|
1868
1873
|
strict: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ union([/* @__PURE__ */ boolean(), /* @__PURE__ */ literal("auto")])), /* @__PURE__ */ description("Whether to always output `\"use strict\"` directive in non-ES module outputs.")),
|
|
1874
|
+
persistentCache: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Enable persistent transform cache to disk.")),
|
|
1869
1875
|
globalIdentifiers: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ array(/* @__PURE__ */ string())), /* @__PURE__ */ description("Reserved global identifiers to be avoided when generating export binding names for module chunks"))
|
|
1870
1876
|
});
|
|
1871
1877
|
isTypeTrue();
|
|
@@ -1884,7 +1890,7 @@ const OutputCliOverrideSchema = /* @__PURE__ */ strictObject({
|
|
|
1884
1890
|
intro: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ string()), /* @__PURE__ */ description(getAddonDescription("top", "inside"))),
|
|
1885
1891
|
outro: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ string()), /* @__PURE__ */ description(getAddonDescription("bottom", "inside"))),
|
|
1886
1892
|
esModule: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Always generate `__esModule` marks in non-ESM formats, defaults to `if-default-prop` (use `--no-esModule` to always disable)")),
|
|
1887
|
-
globals: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ record(/* @__PURE__ */ string(), /* @__PURE__ */ string())), /* @__PURE__ */ description("Global variable of UMD / IIFE dependencies (syntax: `key
|
|
1893
|
+
globals: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ record(/* @__PURE__ */ string(), /* @__PURE__ */ string())), /* @__PURE__ */ description("Global variable of UMD / IIFE dependencies (syntax: `key:value`)")),
|
|
1888
1894
|
codeSplitting: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ union([/* @__PURE__ */ boolean(), /* @__PURE__ */ strictObject({
|
|
1889
1895
|
minSize: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ number()), /* @__PURE__ */ description("Minimum size of the chunk")),
|
|
1890
1896
|
minShareCount: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ number()), /* @__PURE__ */ description("Minimum share count of the chunk"))
|
|
@@ -2971,7 +2977,7 @@ function createTestingLogger() {
|
|
|
2971
2977
|
//#endregion
|
|
2972
2978
|
//#region src/utils/bindingify-output-options.ts
|
|
2973
2979
|
function bindingifyOutputOptions(outputOptions) {
|
|
2974
|
-
const { dir, format, exports, hashCharacters, sourcemap, sourcemapBaseUrl, sourcemapDebugIds, sourcemapIgnoreList, sourcemapPathTransform, name, assetFileNames, entryFileNames, chunkFileNames, banner, footer, postBanner, postFooter, intro, outro, esModule, globals, paths, generatedCode, file, sanitizeFileName, preserveModules, virtualDirname, legalComments, comments, preserveModulesRoot, manualChunks, topLevelVar, cleanDir, strictExecutionOrder, globalIdentifiers } = outputOptions;
|
|
2980
|
+
const { dir, format, exports, hashCharacters, sourcemap, sourcemapBaseUrl, sourcemapDebugIds, sourcemapExcludeSources, sourcemapIgnoreList, sourcemapPathTransform, name, assetFileNames, entryFileNames, chunkFileNames, banner, footer, postBanner, postFooter, intro, outro, esModule, globals, paths, generatedCode, file, sanitizeFileName, preserveModules, virtualDirname, legalComments, comments, preserveModulesRoot, manualChunks, topLevelVar, cleanDir, strictExecutionOrder, globalIdentifiers } = outputOptions;
|
|
2975
2981
|
if (legalComments != null) logger.warn("`legalComments` option is deprecated, please use `comments.legal` instead.");
|
|
2976
2982
|
const { inlineDynamicImports, advancedChunks } = bindingifyCodeSplitting(outputOptions.codeSplitting, outputOptions.inlineDynamicImports, outputOptions.advancedChunks, manualChunks);
|
|
2977
2983
|
return {
|
|
@@ -2983,6 +2989,7 @@ function bindingifyOutputOptions(outputOptions) {
|
|
|
2983
2989
|
sourcemap: bindingifySourcemap(sourcemap),
|
|
2984
2990
|
sourcemapBaseUrl,
|
|
2985
2991
|
sourcemapDebugIds,
|
|
2992
|
+
sourcemapExcludeSources,
|
|
2986
2993
|
sourcemapIgnoreList: sourcemapIgnoreList ?? /node_modules/,
|
|
2987
2994
|
sourcemapPathTransform,
|
|
2988
2995
|
banner: bindingifyAddon(banner),
|
|
@@ -3018,6 +3025,7 @@ function bindingifyOutputOptions(outputOptions) {
|
|
|
3018
3025
|
cleanDir,
|
|
3019
3026
|
strictExecutionOrder,
|
|
3020
3027
|
strict: outputOptions.strict,
|
|
3028
|
+
persistentCache: outputOptions.persistentCache,
|
|
3021
3029
|
globalIdentifiers
|
|
3022
3030
|
};
|
|
3023
3031
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as validateOption, t as RolldownBuild, u as PluginDriver } from "./rolldown-build-
|
|
1
|
+
import { c as validateOption, t as RolldownBuild, u as PluginDriver } from "./rolldown-build-CLB7U-T8.mjs";
|
|
2
2
|
//#region src/api/rolldown/index.ts
|
|
3
3
|
/**
|
|
4
4
|
* The API compatible with Rollup's `rollup` function.
|
|
@@ -1,6 +1,23 @@
|
|
|
1
1
|
import { a as RolldownLog } from "./logging-C6h4g8dA.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { B as ParserOptions$1, I as MinifyOptions$1, K as TsconfigCache$1, L as MinifyResult$1, W as SourceMap, a as BindingEnhancedTransformOptions, b as BindingTsconfigResult, o as BindingEnhancedTransformResult, z as ParseResult$1 } from "./binding-BEVObikP.mjs";
|
|
3
3
|
|
|
4
|
+
//#region src/utils/resolve-tsconfig.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* Cache for tsconfig resolution to avoid redundant file system operations.
|
|
7
|
+
*
|
|
8
|
+
* The cache stores resolved tsconfig configurations keyed by their file paths.
|
|
9
|
+
* When transforming multiple files in the same project, tsconfig lookups are
|
|
10
|
+
* deduplicated, improving performance.
|
|
11
|
+
*
|
|
12
|
+
* @category Utilities
|
|
13
|
+
* @experimental
|
|
14
|
+
*/
|
|
15
|
+
declare class TsconfigCache extends TsconfigCache$1 {
|
|
16
|
+
constructor();
|
|
17
|
+
}
|
|
18
|
+
/** @hidden This is only expected to be used by Vite */
|
|
19
|
+
declare function resolveTsconfig(filename: string, cache?: TsconfigCache | null): BindingTsconfigResult | null;
|
|
20
|
+
//#endregion
|
|
4
21
|
//#region src/utils/parse.d.ts
|
|
5
22
|
/**
|
|
6
23
|
* Result of parsing a code
|
|
@@ -129,4 +146,4 @@ declare function transform(filename: string, sourceText: string, options?: Trans
|
|
|
129
146
|
*/
|
|
130
147
|
declare function transformSync(filename: string, sourceText: string, options?: TransformOptions | null, cache?: TsconfigCache | null): TransformResult;
|
|
131
148
|
//#endregion
|
|
132
|
-
export { MinifyOptions as a, minifySync as c, parse as d, parseSync as f, transformSync as i, ParseResult as l, TransformResult as n, MinifyResult as o, transform as r, minify as s, TransformOptions as t, ParserOptions as u };
|
|
149
|
+
export { MinifyOptions as a, minifySync as c, parse as d, parseSync as f, transformSync as i, ParseResult as l, resolveTsconfig as m, TransformResult as n, MinifyResult as o, TsconfigCache as p, transform as r, minify as s, TransformOptions as t, ParserOptions as u };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { n as __toESM, t as require_binding } from "./binding-
|
|
1
|
+
import { n as __toESM, t as require_binding } from "./binding-BaD00V3B.mjs";
|
|
2
2
|
import { o as logMultipleWatcherOption } from "./logs-D80CXhvg.mjs";
|
|
3
|
-
import {
|
|
3
|
+
import { v as LOG_LEVEL_WARN } from "./bindingify-input-options-KbcygofY.mjs";
|
|
4
4
|
import { t as arraify } from "./misc-DJYbNKZX.mjs";
|
|
5
|
-
import { n as createBundlerOptions, u as PluginDriver } from "./rolldown-build-
|
|
6
|
-
import { t as aggregateBindingErrorsIntoJsError } from "./error-
|
|
5
|
+
import { n as createBundlerOptions, u as PluginDriver } from "./rolldown-build-CLB7U-T8.mjs";
|
|
6
|
+
import { t as aggregateBindingErrorsIntoJsError } from "./error-DMdvzIth.mjs";
|
|
7
7
|
//#region ../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/signals.js
|
|
8
8
|
/**
|
|
9
9
|
* This is not the set of all possible signals.
|
package/dist/utils-index.d.mts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { a as MinifyOptions, c as minifySync, d as parse, f as parseSync, i as transformSync, l as ParseResult, n as TransformResult, o as MinifyResult, r as transform, s as minify, t as TransformOptions, u as ParserOptions } from "./shared/transform-
|
|
1
|
+
import { v as BindingTsconfigCompilerOptions, y as BindingTsconfigRawOptions } from "./shared/binding-BEVObikP.mjs";
|
|
2
|
+
import { a as MinifyOptions, c as minifySync, d as parse, f as parseSync, i as transformSync, l as ParseResult, n as TransformResult, o as MinifyResult, p as TsconfigCache, r as transform, s as minify, t as TransformOptions, u as ParserOptions } from "./shared/transform-CHWi6pVJ.mjs";
|
|
3
3
|
import * as ESTree from "@oxc-project/types";
|
|
4
4
|
import { Program } from "@oxc-project/types";
|
|
5
5
|
|
|
6
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
6
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.121.0/node_modules/oxc-parser/src-js/generated/visit/visitor.d.ts
|
|
7
7
|
interface VisitorObject$1 {
|
|
8
8
|
DebuggerStatement?: (node: ESTree.DebuggerStatement) => void;
|
|
9
9
|
"DebuggerStatement:exit"?: (node: ESTree.DebuggerStatement) => void;
|
package/dist/utils-index.mjs
CHANGED
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import "./shared/
|
|
2
|
-
import "./shared/
|
|
3
|
-
|
|
4
|
-
import { a as minifySync, i as minify, n as transform, r as transformSync, t as import_binding } from "./shared/transform-Cbhgjik0.mjs";
|
|
5
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.115.0/node_modules/oxc-parser/src-js/generated/visit/walk.js
|
|
1
|
+
import { n as parseSync, t as parse } from "./shared/parse-B_pfrOxH.mjs";
|
|
2
|
+
import { a as minify, i as transformSync, o as minifySync, r as transform, t as TsconfigCache } from "./shared/resolve-tsconfig-C4k6MVJe.mjs";
|
|
3
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.121.0/node_modules/oxc-parser/src-js/generated/visit/walk.js
|
|
6
4
|
function walkNode(node, visitors) {
|
|
7
5
|
if (node == null) return;
|
|
8
6
|
if (Array.isArray(node)) {
|
|
@@ -2012,7 +2010,7 @@ function walkTSUnionType(node, visitors) {
|
|
|
2012
2010
|
exit !== null && exit(node);
|
|
2013
2011
|
}
|
|
2014
2012
|
//#endregion
|
|
2015
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
2013
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.121.0/node_modules/oxc-parser/src-js/generated/visit/type_ids.js
|
|
2016
2014
|
/** Mapping from node type name to node type ID */
|
|
2017
2015
|
const NODE_TYPE_IDS_MAP = new Map([
|
|
2018
2016
|
["DebuggerStatement", 0],
|
|
@@ -2182,7 +2180,7 @@ const NODE_TYPE_IDS_MAP = new Map([
|
|
|
2182
2180
|
["TSUnionType", 164]
|
|
2183
2181
|
]);
|
|
2184
2182
|
//#endregion
|
|
2185
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.
|
|
2183
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.121.0/node_modules/oxc-parser/src-js/visit/visitor.js
|
|
2186
2184
|
let compiledVisitor;
|
|
2187
2185
|
function createCompiledVisitor() {
|
|
2188
2186
|
compiledVisitor = [];
|
|
@@ -2413,5 +2411,4 @@ var Visitor = class {
|
|
|
2413
2411
|
}
|
|
2414
2412
|
};
|
|
2415
2413
|
//#endregion
|
|
2416
|
-
var TsconfigCache = import_binding.TsconfigCache;
|
|
2417
2414
|
export { TsconfigCache, Visitor, minify, minifySync, parse, parseSync, transform, transformSync };
|