@rolldown/browser 1.0.0-beta.22 → 1.0.0-beta.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.cjs +8 -8
- package/dist/cli.mjs +8 -8
- package/dist/config.cjs +4 -4
- package/dist/config.d.cts +2 -2
- package/dist/config.d.mts +2 -2
- package/dist/config.mjs +4 -4
- package/dist/experimental-index.browser.mjs +2 -2
- package/dist/experimental-index.cjs +3 -4
- package/dist/experimental-index.d.cts +3 -6
- package/dist/experimental-index.d.mts +3 -6
- package/dist/experimental-index.mjs +4 -4
- package/dist/experimental-runtime-types.d.ts +1 -2
- package/dist/filter-index.cjs +1 -1
- package/dist/filter-index.d.cts +2 -2
- package/dist/filter-index.d.mts +2 -2
- package/dist/filter-index.mjs +1 -1
- package/dist/index.browser.mjs +1 -1
- package/dist/index.cjs +3 -3
- package/dist/index.d.cts +3 -3
- package/dist/index.d.mts +3 -3
- package/dist/index.mjs +3 -3
- package/dist/parallel-plugin-worker.cjs +4 -4
- package/dist/parallel-plugin-worker.mjs +4 -4
- package/dist/parallel-plugin.d.cts +2 -2
- package/dist/parallel-plugin.d.mts +2 -2
- package/dist/parse-ast-index.cjs +1 -1
- package/dist/parse-ast-index.d.cts +1 -1
- package/dist/parse-ast-index.d.mts +1 -1
- package/dist/parse-ast-index.mjs +1 -1
- package/dist/rolldown-binding.wasi-browser.js +0 -3
- package/dist/rolldown-binding.wasi.cjs +0 -3
- package/dist/rolldown-binding.wasm32-wasi.wasm +0 -0
- package/dist/shared/{binding-B8kHDLfO.d.mts → binding-DG3bbtXG.d.cts} +4 -22
- package/dist/shared/{binding-CbR_BHh9.d.cts → binding-cECB-Ts3.d.mts} +4 -22
- package/dist/shared/{define-config-DZVEpUTF.d.cts → define-config-BnlWQIlM.d.cts} +20 -22
- package/dist/shared/{define-config-DsN80oVh.d.mts → define-config-Dipre2WB.d.mts} +20 -22
- package/dist/shared/{dist-BMVjvV-v.cjs → dist-BVAp8sOm.cjs} +0 -9
- package/dist/shared/{dist-BoWaIc-K.mjs → dist-DvBwroyk.mjs} +1 -4
- package/dist/shared/{load-config-BgXwAVNp.cjs → load-config-B-Wrkmqo.cjs} +1 -1
- package/dist/shared/{load-config-_2H4hlKT.mjs → load-config-FXcGLoFh.mjs} +1 -1
- package/dist/shared/{parse-ast-index-CGTVCgvx.cjs → parse-ast-index-B0vXlNs8.cjs} +14 -2
- package/dist/shared/{parse-ast-index-BzdtcWzA.mjs → parse-ast-index-DQEVpsUG.mjs} +9 -3
- package/dist/shared/{src-C_vfq91X.mjs → src-DmJCtJ15.mjs} +499 -793
- package/dist/shared/{src-DT8g8X-x.cjs → src-dEUToPiW.cjs} +482 -782
- package/dist/{src-DJeuVN_z.js → src-BHNQaKQh.js} +532 -823
- package/package.json +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BindingAssetPluginConfig, BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingBundlerImpl,
|
|
1
|
+
import { BindingAssetPluginConfig, BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingBundlerImpl, BindingDynamicImportVarsPluginConfig, BindingHmrOutputPatch, BindingHookResolveIdExtraArgs, BindingImportGlobPluginConfig, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReporterPluginConfig, BindingTransformHookExtraArgs, BindingViteResolvePluginConfig, BindingWasmHelperPluginConfig, BindingWatcherEvent, ParserOptions, PreRenderedChunk, TransformOptions } from "./binding-DG3bbtXG.cjs";
|
|
2
2
|
import { Program } from "@oxc-project/types";
|
|
3
3
|
import { TopLevelFilterExpression } from "@rolldown/pluginutils";
|
|
4
4
|
|
|
@@ -38,6 +38,10 @@ interface RollupError extends RollupLog {
|
|
|
38
38
|
}
|
|
39
39
|
type LogOrStringHandler = (level: LogLevelWithError, log: RollupLogWithString) => void;
|
|
40
40
|
//#endregion
|
|
41
|
+
//#region src/types/misc.d.ts
|
|
42
|
+
type SourcemapPathTransformOption = (relativeSourcePath: string, sourcemapPath: string) => string;
|
|
43
|
+
type SourcemapIgnoreListOption = (relativeSourcePath: string, sourcemapPath: string) => boolean;
|
|
44
|
+
//#endregion
|
|
41
45
|
//#region src/types/module-info.d.ts
|
|
42
46
|
interface ModuleInfo extends ModuleOptions {
|
|
43
47
|
/**
|
|
@@ -54,17 +58,6 @@ interface ModuleInfo extends ModuleOptions {
|
|
|
54
58
|
isEntry: boolean;
|
|
55
59
|
}
|
|
56
60
|
//#endregion
|
|
57
|
-
//#region src/types/chunking-context.d.ts
|
|
58
|
-
declare class ChunkingContext {
|
|
59
|
-
private context;
|
|
60
|
-
constructor(context: BindingChunkingContext);
|
|
61
|
-
getModuleInfo(moduleId: string): ModuleInfo | null;
|
|
62
|
-
}
|
|
63
|
-
//#endregion
|
|
64
|
-
//#region src/types/misc.d.ts
|
|
65
|
-
type SourcemapPathTransformOption = (relativeSourcePath: string, sourcemapPath: string) => string;
|
|
66
|
-
type SourcemapIgnoreListOption = (relativeSourcePath: string, sourcemapPath: string) => boolean;
|
|
67
|
-
//#endregion
|
|
68
61
|
//#region src/utils/asset-source.d.ts
|
|
69
62
|
type AssetSource = string | Uint8Array;
|
|
70
63
|
//#endregion
|
|
@@ -156,6 +149,9 @@ interface PreRenderedAsset {
|
|
|
156
149
|
type AssetFileNamesFunction = (chunkInfo: PreRenderedAsset) => string;
|
|
157
150
|
type GlobalsFunction = (name: string) => string;
|
|
158
151
|
type MinifyOptions = BindingMinifyOptions;
|
|
152
|
+
interface ChunkingContext {
|
|
153
|
+
getModuleInfo(moduleId: string): ModuleInfo | null;
|
|
154
|
+
}
|
|
159
155
|
interface OutputOptions {
|
|
160
156
|
dir?: string;
|
|
161
157
|
file?: string;
|
|
@@ -735,11 +731,15 @@ declare class BuiltinPlugin {
|
|
|
735
731
|
constructor(name: BindingBuiltinPluginName, _options?: unknown);
|
|
736
732
|
}
|
|
737
733
|
declare function modulePreloadPolyfillPlugin(config?: BindingModulePreloadPolyfillPluginConfig): BuiltinPlugin;
|
|
738
|
-
|
|
734
|
+
type DynamicImportVarsPluginConfig = Omit<BindingDynamicImportVarsPluginConfig, "include" | "exclude"> & {
|
|
735
|
+
include?: StringOrRegExp | StringOrRegExp[];
|
|
736
|
+
exclude?: StringOrRegExp | StringOrRegExp[];
|
|
737
|
+
};
|
|
738
|
+
declare function dynamicImportVarsPlugin(config?: DynamicImportVarsPluginConfig): BuiltinPlugin;
|
|
739
739
|
declare function importGlobPlugin(config?: BindingImportGlobPluginConfig): BuiltinPlugin;
|
|
740
740
|
declare function reporterPlugin(config?: BindingReporterPluginConfig): BuiltinPlugin;
|
|
741
741
|
declare function manifestPlugin(config?: BindingManifestPluginConfig): BuiltinPlugin;
|
|
742
|
-
declare function wasmHelperPlugin(): BuiltinPlugin;
|
|
742
|
+
declare function wasmHelperPlugin(config?: BindingWasmHelperPluginConfig): BuiltinPlugin;
|
|
743
743
|
declare function wasmFallbackPlugin(): BuiltinPlugin;
|
|
744
744
|
declare function loadFallbackPlugin(): BuiltinPlugin;
|
|
745
745
|
declare function jsonPlugin(config?: BindingJsonPluginConfig): BuiltinPlugin;
|
|
@@ -758,11 +758,6 @@ declare function webWorkerPostPlugin(): BuiltinPlugin;
|
|
|
758
758
|
declare const ENUMERATED_INPUT_PLUGIN_HOOK_NAMES: readonly ["options", "buildStart", "resolveId", "load", "transform", "moduleParsed", "buildEnd", "onLog", "resolveDynamicImport", "closeBundle", "closeWatcher", "watchChange"];
|
|
759
759
|
declare const ENUMERATED_OUTPUT_PLUGIN_HOOK_NAMES: readonly ["augmentChunkHash", "outputOptions", "renderChunk", "renderStart", "renderError", "writeBundle", "generateBundle"];
|
|
760
760
|
declare const ENUMERATED_PLUGIN_HOOK_NAMES: [...typeof ENUMERATED_INPUT_PLUGIN_HOOK_NAMES, ...typeof ENUMERATED_OUTPUT_PLUGIN_HOOK_NAMES, "footer", "banner", "intro", "outro"];
|
|
761
|
-
type EnumeratedPluginHookNames = typeof ENUMERATED_PLUGIN_HOOK_NAMES;
|
|
762
|
-
/**
|
|
763
|
-
* Names of all hooks in a `Plugin` object. Does not include `name` and `api`, since they are not hooks.
|
|
764
|
-
*/
|
|
765
|
-
type PluginHookNames = EnumeratedPluginHookNames[number];
|
|
766
761
|
/**
|
|
767
762
|
* Names of all defined hooks. It's like
|
|
768
763
|
* ```ts
|
|
@@ -773,7 +768,7 @@ type PluginHookNames = EnumeratedPluginHookNames[number];
|
|
|
773
768
|
* }
|
|
774
769
|
* ```
|
|
775
770
|
*/
|
|
776
|
-
type DefinedHookNames = { readonly [K in
|
|
771
|
+
type DefinedHookNames = { readonly [K in typeof ENUMERATED_PLUGIN_HOOK_NAMES[number]]: K };
|
|
777
772
|
/**
|
|
778
773
|
* Names of all defined hooks. It's like
|
|
779
774
|
* ```js
|
|
@@ -1011,6 +1006,9 @@ type HmrOptions = boolean | {
|
|
|
1011
1006
|
port?: number;
|
|
1012
1007
|
implement?: string;
|
|
1013
1008
|
};
|
|
1009
|
+
type OptimizationOptions = {
|
|
1010
|
+
inlineConst?: boolean;
|
|
1011
|
+
};
|
|
1014
1012
|
type AttachDebugOptions = "none" | "simple" | "full";
|
|
1015
1013
|
interface RollupJsxOptions {
|
|
1016
1014
|
mode?: "classic" | "automatic" | "preserve";
|
|
@@ -1064,7 +1062,6 @@ interface InputOptions {
|
|
|
1064
1062
|
onwarn?: (warning: RollupLog, defaultHandler: (warning: RollupLogWithString | (() => RollupLogWithString)) => void) => void;
|
|
1065
1063
|
moduleTypes?: ModuleTypes;
|
|
1066
1064
|
experimental?: {
|
|
1067
|
-
enableComposingJsPlugins?: boolean;
|
|
1068
1065
|
strictExecutionOrder?: boolean;
|
|
1069
1066
|
disableLiveBindings?: boolean;
|
|
1070
1067
|
viteMode?: boolean;
|
|
@@ -1193,6 +1190,7 @@ interface InputOptions {
|
|
|
1193
1190
|
sessionId?: string;
|
|
1194
1191
|
};
|
|
1195
1192
|
preserveEntrySignatures?: false | "strict" | "allow-extension" | "exports-only";
|
|
1193
|
+
optimization?: OptimizationOptions;
|
|
1196
1194
|
}
|
|
1197
1195
|
//#endregion
|
|
1198
1196
|
//#region src/types/rolldown-options.d.ts
|
|
@@ -1211,4 +1209,4 @@ declare function defineConfig(config: RolldownOptions): RolldownOptions;
|
|
|
1211
1209
|
declare function defineConfig(config: RolldownOptions[]): RolldownOptions[];
|
|
1212
1210
|
declare function defineConfig(config: ConfigExport): ConfigExport;
|
|
1213
1211
|
//#endregion
|
|
1214
|
-
export { AddonFunction, AsyncPluginHooks, BuildOptions, BuiltinPlugin, ChunkFileNamesFunction, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GeneralHookFilter, GetModuleInfo, GlobalsFunction, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, LoadResult, LogLevel, LogLevelOption, LogOrStringHandler, LoggingFunction, MaybePromise, MinifyOptions, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, ModuleTypes, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RolldownWatcherEvent, RollupError, RollupLog, RollupLogWithString, SourceDescription, SourceMap, SourceMapInput, SourcemapIgnoreListOption, TransformPluginContext, TransformResult, TreeshakingOptions, VERSION, WarningHandlerWithDefault, WatchOptions, WatcherOptions, assetPlugin, build, buildImportAnalysisPlugin, defineConfig, defineParallelPlugin, dynamicImportVarsPlugin, importGlobPlugin, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, reporterPlugin, rolldown, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin, watch, webWorkerPostPlugin, withFilter };
|
|
1212
|
+
export { AddonFunction, AsyncPluginHooks, BuildOptions, BuiltinPlugin, ChunkFileNamesFunction, ChunkingContext, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GeneralHookFilter, GetModuleInfo, GlobalsFunction, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, LoadResult, LogLevel, LogLevelOption, LogOrStringHandler, LoggingFunction, MaybePromise, MinifyOptions, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, ModuleTypes, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OptimizationOptions, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RolldownWatcherEvent, RollupError, RollupLog, RollupLogWithString, SourceDescription, SourceMap, SourceMapInput, SourcemapIgnoreListOption, TransformPluginContext, TransformResult, TreeshakingOptions, VERSION, WarningHandlerWithDefault, WatchOptions, WatcherOptions, assetPlugin, build, buildImportAnalysisPlugin, defineConfig, defineParallelPlugin, dynamicImportVarsPlugin, importGlobPlugin, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, reporterPlugin, rolldown, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin, watch, webWorkerPostPlugin, withFilter };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BindingAssetPluginConfig, BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingBundlerImpl,
|
|
1
|
+
import { BindingAssetPluginConfig, BindingBuildImportAnalysisPluginConfig, BindingBuiltinPluginName, BindingBundlerImpl, BindingDynamicImportVarsPluginConfig, BindingHmrOutputPatch, BindingHookResolveIdExtraArgs, BindingImportGlobPluginConfig, BindingIsolatedDeclarationPluginConfig, BindingJsonPluginConfig, BindingManifestPluginConfig, BindingMfManifest, BindingMinifyOptions, BindingModuleFederationPluginOption, BindingModulePreloadPolyfillPluginConfig, BindingRemote, BindingRenderedChunk, BindingReporterPluginConfig, BindingTransformHookExtraArgs, BindingViteResolvePluginConfig, BindingWasmHelperPluginConfig, BindingWatcherEvent, ParserOptions, PreRenderedChunk, TransformOptions } from "./binding-cECB-Ts3.mjs";
|
|
2
2
|
import { Program } from "@oxc-project/types";
|
|
3
3
|
import { TopLevelFilterExpression } from "@rolldown/pluginutils";
|
|
4
4
|
|
|
@@ -38,6 +38,10 @@ interface RollupError extends RollupLog {
|
|
|
38
38
|
}
|
|
39
39
|
type LogOrStringHandler = (level: LogLevelWithError, log: RollupLogWithString) => void;
|
|
40
40
|
//#endregion
|
|
41
|
+
//#region src/types/misc.d.ts
|
|
42
|
+
type SourcemapPathTransformOption = (relativeSourcePath: string, sourcemapPath: string) => string;
|
|
43
|
+
type SourcemapIgnoreListOption = (relativeSourcePath: string, sourcemapPath: string) => boolean;
|
|
44
|
+
//#endregion
|
|
41
45
|
//#region src/types/module-info.d.ts
|
|
42
46
|
interface ModuleInfo extends ModuleOptions {
|
|
43
47
|
/**
|
|
@@ -54,17 +58,6 @@ interface ModuleInfo extends ModuleOptions {
|
|
|
54
58
|
isEntry: boolean;
|
|
55
59
|
}
|
|
56
60
|
//#endregion
|
|
57
|
-
//#region src/types/chunking-context.d.ts
|
|
58
|
-
declare class ChunkingContext {
|
|
59
|
-
private context;
|
|
60
|
-
constructor(context: BindingChunkingContext);
|
|
61
|
-
getModuleInfo(moduleId: string): ModuleInfo | null;
|
|
62
|
-
}
|
|
63
|
-
//#endregion
|
|
64
|
-
//#region src/types/misc.d.ts
|
|
65
|
-
type SourcemapPathTransformOption = (relativeSourcePath: string, sourcemapPath: string) => string;
|
|
66
|
-
type SourcemapIgnoreListOption = (relativeSourcePath: string, sourcemapPath: string) => boolean;
|
|
67
|
-
//#endregion
|
|
68
61
|
//#region src/utils/asset-source.d.ts
|
|
69
62
|
type AssetSource = string | Uint8Array;
|
|
70
63
|
//#endregion
|
|
@@ -156,6 +149,9 @@ interface PreRenderedAsset {
|
|
|
156
149
|
type AssetFileNamesFunction = (chunkInfo: PreRenderedAsset) => string;
|
|
157
150
|
type GlobalsFunction = (name: string) => string;
|
|
158
151
|
type MinifyOptions = BindingMinifyOptions;
|
|
152
|
+
interface ChunkingContext {
|
|
153
|
+
getModuleInfo(moduleId: string): ModuleInfo | null;
|
|
154
|
+
}
|
|
159
155
|
interface OutputOptions {
|
|
160
156
|
dir?: string;
|
|
161
157
|
file?: string;
|
|
@@ -735,11 +731,15 @@ declare class BuiltinPlugin {
|
|
|
735
731
|
constructor(name: BindingBuiltinPluginName, _options?: unknown);
|
|
736
732
|
}
|
|
737
733
|
declare function modulePreloadPolyfillPlugin(config?: BindingModulePreloadPolyfillPluginConfig): BuiltinPlugin;
|
|
738
|
-
|
|
734
|
+
type DynamicImportVarsPluginConfig = Omit<BindingDynamicImportVarsPluginConfig, "include" | "exclude"> & {
|
|
735
|
+
include?: StringOrRegExp | StringOrRegExp[];
|
|
736
|
+
exclude?: StringOrRegExp | StringOrRegExp[];
|
|
737
|
+
};
|
|
738
|
+
declare function dynamicImportVarsPlugin(config?: DynamicImportVarsPluginConfig): BuiltinPlugin;
|
|
739
739
|
declare function importGlobPlugin(config?: BindingImportGlobPluginConfig): BuiltinPlugin;
|
|
740
740
|
declare function reporterPlugin(config?: BindingReporterPluginConfig): BuiltinPlugin;
|
|
741
741
|
declare function manifestPlugin(config?: BindingManifestPluginConfig): BuiltinPlugin;
|
|
742
|
-
declare function wasmHelperPlugin(): BuiltinPlugin;
|
|
742
|
+
declare function wasmHelperPlugin(config?: BindingWasmHelperPluginConfig): BuiltinPlugin;
|
|
743
743
|
declare function wasmFallbackPlugin(): BuiltinPlugin;
|
|
744
744
|
declare function loadFallbackPlugin(): BuiltinPlugin;
|
|
745
745
|
declare function jsonPlugin(config?: BindingJsonPluginConfig): BuiltinPlugin;
|
|
@@ -758,11 +758,6 @@ declare function webWorkerPostPlugin(): BuiltinPlugin;
|
|
|
758
758
|
declare const ENUMERATED_INPUT_PLUGIN_HOOK_NAMES: readonly ["options", "buildStart", "resolveId", "load", "transform", "moduleParsed", "buildEnd", "onLog", "resolveDynamicImport", "closeBundle", "closeWatcher", "watchChange"];
|
|
759
759
|
declare const ENUMERATED_OUTPUT_PLUGIN_HOOK_NAMES: readonly ["augmentChunkHash", "outputOptions", "renderChunk", "renderStart", "renderError", "writeBundle", "generateBundle"];
|
|
760
760
|
declare const ENUMERATED_PLUGIN_HOOK_NAMES: [...typeof ENUMERATED_INPUT_PLUGIN_HOOK_NAMES, ...typeof ENUMERATED_OUTPUT_PLUGIN_HOOK_NAMES, "footer", "banner", "intro", "outro"];
|
|
761
|
-
type EnumeratedPluginHookNames = typeof ENUMERATED_PLUGIN_HOOK_NAMES;
|
|
762
|
-
/**
|
|
763
|
-
* Names of all hooks in a `Plugin` object. Does not include `name` and `api`, since they are not hooks.
|
|
764
|
-
*/
|
|
765
|
-
type PluginHookNames = EnumeratedPluginHookNames[number];
|
|
766
761
|
/**
|
|
767
762
|
* Names of all defined hooks. It's like
|
|
768
763
|
* ```ts
|
|
@@ -773,7 +768,7 @@ type PluginHookNames = EnumeratedPluginHookNames[number];
|
|
|
773
768
|
* }
|
|
774
769
|
* ```
|
|
775
770
|
*/
|
|
776
|
-
type DefinedHookNames = { readonly [K in
|
|
771
|
+
type DefinedHookNames = { readonly [K in typeof ENUMERATED_PLUGIN_HOOK_NAMES[number]]: K };
|
|
777
772
|
/**
|
|
778
773
|
* Names of all defined hooks. It's like
|
|
779
774
|
* ```js
|
|
@@ -1011,6 +1006,9 @@ type HmrOptions = boolean | {
|
|
|
1011
1006
|
port?: number;
|
|
1012
1007
|
implement?: string;
|
|
1013
1008
|
};
|
|
1009
|
+
type OptimizationOptions = {
|
|
1010
|
+
inlineConst?: boolean;
|
|
1011
|
+
};
|
|
1014
1012
|
type AttachDebugOptions = "none" | "simple" | "full";
|
|
1015
1013
|
interface RollupJsxOptions {
|
|
1016
1014
|
mode?: "classic" | "automatic" | "preserve";
|
|
@@ -1064,7 +1062,6 @@ interface InputOptions {
|
|
|
1064
1062
|
onwarn?: (warning: RollupLog, defaultHandler: (warning: RollupLogWithString | (() => RollupLogWithString)) => void) => void;
|
|
1065
1063
|
moduleTypes?: ModuleTypes;
|
|
1066
1064
|
experimental?: {
|
|
1067
|
-
enableComposingJsPlugins?: boolean;
|
|
1068
1065
|
strictExecutionOrder?: boolean;
|
|
1069
1066
|
disableLiveBindings?: boolean;
|
|
1070
1067
|
viteMode?: boolean;
|
|
@@ -1193,6 +1190,7 @@ interface InputOptions {
|
|
|
1193
1190
|
sessionId?: string;
|
|
1194
1191
|
};
|
|
1195
1192
|
preserveEntrySignatures?: false | "strict" | "allow-extension" | "exports-only";
|
|
1193
|
+
optimization?: OptimizationOptions;
|
|
1196
1194
|
}
|
|
1197
1195
|
//#endregion
|
|
1198
1196
|
//#region src/types/rolldown-options.d.ts
|
|
@@ -1211,4 +1209,4 @@ declare function defineConfig(config: RolldownOptions): RolldownOptions;
|
|
|
1211
1209
|
declare function defineConfig(config: RolldownOptions[]): RolldownOptions[];
|
|
1212
1210
|
declare function defineConfig(config: ConfigExport): ConfigExport;
|
|
1213
1211
|
//#endregion
|
|
1214
|
-
export { AddonFunction, AsyncPluginHooks, BuildOptions, BuiltinPlugin, ChunkFileNamesFunction, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GeneralHookFilter, GetModuleInfo, GlobalsFunction, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, LoadResult, LogLevel, LogLevelOption, LogOrStringHandler, LoggingFunction, MaybePromise, MinifyOptions, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, ModuleTypes, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RolldownWatcherEvent, RollupError, RollupLog, RollupLogWithString, SourceDescription, SourceMap, SourceMapInput, SourcemapIgnoreListOption, TransformPluginContext, TransformResult, TreeshakingOptions, VERSION, WarningHandlerWithDefault, WatchOptions, WatcherOptions, assetPlugin, build, buildImportAnalysisPlugin, defineConfig, defineParallelPlugin, dynamicImportVarsPlugin, importGlobPlugin, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, reporterPlugin, rolldown, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin, watch, webWorkerPostPlugin, withFilter };
|
|
1212
|
+
export { AddonFunction, AsyncPluginHooks, BuildOptions, BuiltinPlugin, ChunkFileNamesFunction, ChunkingContext, ConfigExport, CustomPluginOptions, DefineParallelPluginResult, EmittedAsset, EmittedFile, ExistingRawSourceMap, ExternalOption, FunctionPluginHooks, GeneralHookFilter, GetModuleInfo, GlobalsFunction, HookFilter, HookFilterExtension, ImportKind, InputOption, InputOptions, InternalModuleFormat, LoadResult, LogLevel, LogLevelOption, LogOrStringHandler, LoggingFunction, MaybePromise, MinifyOptions, MinimalPluginContext, ModuleFormat, ModuleInfo, ModuleOptions, ModuleType, ModuleTypeFilter, ModuleTypes, NormalizedInputOptions, NormalizedOutputOptions, ObjectHook, OptimizationOptions, OutputAsset, OutputBundle, OutputChunk, OutputOptions, ParallelPluginHooks, PartialNull, PartialResolvedId, Plugin, PluginContext, PluginContextMeta, PreRenderedAsset, RenderedChunk, RenderedModule, ResolveIdExtraOptions, ResolveIdResult, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RolldownWatcherEvent, RollupError, RollupLog, RollupLogWithString, SourceDescription, SourceMap, SourceMapInput, SourcemapIgnoreListOption, TransformPluginContext, TransformResult, TreeshakingOptions, VERSION, WarningHandlerWithDefault, WatchOptions, WatcherOptions, assetPlugin, build, buildImportAnalysisPlugin, defineConfig, defineParallelPlugin, dynamicImportVarsPlugin, importGlobPlugin, isolatedDeclarationPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, reporterPlugin, rolldown, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin, watch, webWorkerPostPlugin, withFilter };
|
|
@@ -3,9 +3,6 @@
|
|
|
3
3
|
function arraify(value) {
|
|
4
4
|
return Array.isArray(value) ? value : [value];
|
|
5
5
|
}
|
|
6
|
-
function isNullish(value) {
|
|
7
|
-
return value === null || value === void 0;
|
|
8
|
-
}
|
|
9
6
|
function isPromiseLike(value) {
|
|
10
7
|
return value && (typeof value === "object" || typeof value === "function") && typeof value.then === "function";
|
|
11
8
|
}
|
|
@@ -181,12 +178,6 @@ Object.defineProperty(exports, 'include', {
|
|
|
181
178
|
return include;
|
|
182
179
|
}
|
|
183
180
|
});
|
|
184
|
-
Object.defineProperty(exports, 'isNullish', {
|
|
185
|
-
enumerable: true,
|
|
186
|
-
get: function () {
|
|
187
|
-
return isNullish;
|
|
188
|
-
}
|
|
189
|
-
});
|
|
190
181
|
Object.defineProperty(exports, 'isPromiseLike', {
|
|
191
182
|
enumerable: true,
|
|
192
183
|
get: function () {
|
|
@@ -2,9 +2,6 @@
|
|
|
2
2
|
function arraify(value) {
|
|
3
3
|
return Array.isArray(value) ? value : [value];
|
|
4
4
|
}
|
|
5
|
-
function isNullish(value) {
|
|
6
|
-
return value === null || value === void 0;
|
|
7
|
-
}
|
|
8
5
|
function isPromiseLike(value) {
|
|
9
6
|
return value && (typeof value === "object" || typeof value === "function") && typeof value.then === "function";
|
|
10
7
|
}
|
|
@@ -144,4 +141,4 @@ function queries(queryFilter) {
|
|
|
144
141
|
}
|
|
145
142
|
|
|
146
143
|
//#endregion
|
|
147
|
-
export { and, arraify, code, exclude, id, include,
|
|
144
|
+
export { and, arraify, code, exclude, id, include, isPromiseLike, moduleType, noop, not, or, queries, query, unimplemented, unreachable, unsupported };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const require_chunk = require('./chunk-DDkG_k5U.cjs');
|
|
2
|
-
const require_src = require('./src-
|
|
2
|
+
const require_src = require('./src-dEUToPiW.cjs');
|
|
3
3
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
4
4
|
const node_url = require_chunk.__toESM(require("node:url"));
|
|
5
5
|
const node_process = require_chunk.__toESM(require("node:process"));
|
|
@@ -102,7 +102,7 @@ function locate(source, search, options) {
|
|
|
102
102
|
|
|
103
103
|
//#endregion
|
|
104
104
|
//#region src/log/logs.ts
|
|
105
|
-
const INVALID_LOG_POSITION = "INVALID_LOG_POSITION", PLUGIN_ERROR = "PLUGIN_ERROR", INPUT_HOOK_IN_OUTPUT_PLUGIN = "INPUT_HOOK_IN_OUTPUT_PLUGIN", CYCLE_LOADING = "CYCLE_LOADING", MULTIPLY_NOTIFY_OPTION = "MULTIPLY_NOTIFY_OPTION", PARSE_ERROR = "PARSE_ERROR";
|
|
105
|
+
const INVALID_LOG_POSITION = "INVALID_LOG_POSITION", PLUGIN_ERROR = "PLUGIN_ERROR", INPUT_HOOK_IN_OUTPUT_PLUGIN = "INPUT_HOOK_IN_OUTPUT_PLUGIN", CYCLE_LOADING = "CYCLE_LOADING", MULTIPLY_NOTIFY_OPTION = "MULTIPLY_NOTIFY_OPTION", PARSE_ERROR = "PARSE_ERROR", DUPLICATE_JSX_CONFIG = "DUPLICATE_JSX_CONFIG";
|
|
106
106
|
function logParseError(message) {
|
|
107
107
|
return {
|
|
108
108
|
code: PARSE_ERROR,
|
|
@@ -133,6 +133,12 @@ function logMultiplyNotifyOption() {
|
|
|
133
133
|
message: `Found multiply notify option at watch options, using first one to start notify watcher.`
|
|
134
134
|
};
|
|
135
135
|
}
|
|
136
|
+
function logDuplicateJsxConfig() {
|
|
137
|
+
return {
|
|
138
|
+
code: DUPLICATE_JSX_CONFIG,
|
|
139
|
+
message: "Both `options.jsx` and `options.transform.jsx` are set so `options.jsx` is ignored"
|
|
140
|
+
};
|
|
141
|
+
}
|
|
136
142
|
function logPluginError(error$1, plugin, { hook, id } = {}) {
|
|
137
143
|
try {
|
|
138
144
|
const code = error$1.code;
|
|
@@ -181,7 +187,7 @@ function augmentCodeLocation(properties, pos, source, id) {
|
|
|
181
187
|
}
|
|
182
188
|
|
|
183
189
|
//#endregion
|
|
184
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.75.
|
|
190
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.75.1/node_modules/oxc-parser/wrap.mjs
|
|
185
191
|
function wrap$1(result) {
|
|
186
192
|
let program, module$1, comments, errors;
|
|
187
193
|
return {
|
|
@@ -276,6 +282,12 @@ Object.defineProperty(exports, 'logCycleLoading', {
|
|
|
276
282
|
return logCycleLoading;
|
|
277
283
|
}
|
|
278
284
|
});
|
|
285
|
+
Object.defineProperty(exports, 'logDuplicateJsxConfig', {
|
|
286
|
+
enumerable: true,
|
|
287
|
+
get: function () {
|
|
288
|
+
return logDuplicateJsxConfig;
|
|
289
|
+
}
|
|
290
|
+
});
|
|
279
291
|
Object.defineProperty(exports, 'logInputHookInOutputPlugin', {
|
|
280
292
|
enumerable: true,
|
|
281
293
|
get: function () {
|
|
@@ -101,7 +101,7 @@ function locate(source, search, options) {
|
|
|
101
101
|
|
|
102
102
|
//#endregion
|
|
103
103
|
//#region src/log/logs.ts
|
|
104
|
-
const INVALID_LOG_POSITION = "INVALID_LOG_POSITION", PLUGIN_ERROR = "PLUGIN_ERROR", INPUT_HOOK_IN_OUTPUT_PLUGIN = "INPUT_HOOK_IN_OUTPUT_PLUGIN", CYCLE_LOADING = "CYCLE_LOADING", MULTIPLY_NOTIFY_OPTION = "MULTIPLY_NOTIFY_OPTION", PARSE_ERROR = "PARSE_ERROR";
|
|
104
|
+
const INVALID_LOG_POSITION = "INVALID_LOG_POSITION", PLUGIN_ERROR = "PLUGIN_ERROR", INPUT_HOOK_IN_OUTPUT_PLUGIN = "INPUT_HOOK_IN_OUTPUT_PLUGIN", CYCLE_LOADING = "CYCLE_LOADING", MULTIPLY_NOTIFY_OPTION = "MULTIPLY_NOTIFY_OPTION", PARSE_ERROR = "PARSE_ERROR", DUPLICATE_JSX_CONFIG = "DUPLICATE_JSX_CONFIG";
|
|
105
105
|
function logParseError(message) {
|
|
106
106
|
return {
|
|
107
107
|
code: PARSE_ERROR,
|
|
@@ -132,6 +132,12 @@ function logMultiplyNotifyOption() {
|
|
|
132
132
|
message: `Found multiply notify option at watch options, using first one to start notify watcher.`
|
|
133
133
|
};
|
|
134
134
|
}
|
|
135
|
+
function logDuplicateJsxConfig() {
|
|
136
|
+
return {
|
|
137
|
+
code: DUPLICATE_JSX_CONFIG,
|
|
138
|
+
message: "Both `options.jsx` and `options.transform.jsx` are set so `options.jsx` is ignored"
|
|
139
|
+
};
|
|
140
|
+
}
|
|
135
141
|
function logPluginError(error$1, plugin, { hook, id } = {}) {
|
|
136
142
|
try {
|
|
137
143
|
const code = error$1.code;
|
|
@@ -180,7 +186,7 @@ function augmentCodeLocation(properties, pos, source, id) {
|
|
|
180
186
|
}
|
|
181
187
|
|
|
182
188
|
//#endregion
|
|
183
|
-
//#region ../../node_modules/.pnpm/oxc-parser@0.75.
|
|
189
|
+
//#region ../../node_modules/.pnpm/oxc-parser@0.75.1/node_modules/oxc-parser/wrap.mjs
|
|
184
190
|
function wrap$1(result) {
|
|
185
191
|
let program, module, comments, errors;
|
|
186
192
|
return {
|
|
@@ -257,4 +263,4 @@ async function parseAstAsync(sourceText, options, filename) {
|
|
|
257
263
|
}
|
|
258
264
|
|
|
259
265
|
//#endregion
|
|
260
|
-
export { augmentCodeLocation, error, logCycleLoading, logInputHookInOutputPlugin, logInvalidLogPosition, logMultiplyNotifyOption, logPluginError, parseAst, parseAstAsync };
|
|
266
|
+
export { augmentCodeLocation, error, logCycleLoading, logDuplicateJsxConfig, logInputHookInOutputPlugin, logInvalidLogPosition, logMultiplyNotifyOption, logPluginError, parseAst, parseAstAsync };
|