rolldown 0.14.0 → 0.15.0-snapshot-5e456b6-20241203003703
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/cjs/cli.cjs +782 -854
- package/dist/cjs/experimental-index.cjs +68 -26
- package/dist/cjs/index.cjs +6 -8
- package/dist/cjs/parallel-plugin-worker.cjs +20 -14
- package/dist/cjs/parallel-plugin.cjs +1 -3
- package/dist/esm/cli.mjs +722 -796
- package/dist/esm/experimental-index.mjs +44 -7
- package/dist/esm/index.mjs +2 -4
- package/dist/esm/parallel-plugin-worker.mjs +15 -10
- package/dist/esm/parallel-plugin.mjs +1 -3
- package/dist/shared/{chunk-JoMxl5V2.cjs → chunk-BK2Ye-xa.cjs} +19 -6
- package/dist/shared/{consola.36c0034f-Xyw7SC_7.mjs → consola_36c0034f-DWsVjwtA.mjs} +218 -283
- package/dist/shared/{consola.36c0034f-HcmWcfPe.cjs → consola_36c0034f-_8_dG1Nr.cjs} +249 -295
- package/dist/shared/{prompt-hoPhcrA-.mjs → prompt-DGW8ZJmn.mjs} +125 -174
- package/dist/shared/{prompt-9Ij3R3TG.cjs → prompt-RFvZMmjc.cjs} +157 -204
- package/dist/shared/src-COU7qQBJ.cjs +2899 -0
- package/dist/shared/src-DEPa5yhI.mjs +2771 -0
- package/dist/types/api/build.d.ts +14 -0
- package/dist/types/api/experimental.d.ts +7 -0
- package/dist/types/api/rolldown/index.d.ts +3 -0
- package/dist/types/api/rolldown/rolldown-build.d.ts +12 -0
- package/dist/types/api/watch/index.d.ts +3 -0
- package/dist/types/{watcher.d.ts → api/watch/watcher.d.ts} +5 -3
- package/dist/types/binding.d.ts +175 -40
- package/dist/types/builtin-plugin/alias-plugin.d.ts +10 -0
- package/dist/types/builtin-plugin/constructors.d.ts +20 -0
- package/dist/types/builtin-plugin/replace-plugin.d.ts +28 -0
- package/dist/types/{options/normalized-ecma-transform-plugin-config.d.ts → builtin-plugin/transform-plugin.d.ts} +2 -1
- package/dist/types/builtin-plugin/utils.d.ts +8 -0
- package/dist/types/cli/arguments/normalize.d.ts +2 -6
- package/dist/types/cli/arguments/schema.d.ts +169 -81
- package/dist/types/constants/plugin.d.ts +3 -1
- package/dist/types/experimental-index.d.ts +5 -2
- package/dist/types/index.d.ts +13 -10
- package/dist/types/log/locate-character/index.d.ts +13 -0
- package/dist/types/log/logger.d.ts +2 -16
- package/dist/types/log/logging.d.ts +6 -3
- package/dist/types/log/logs.d.ts +2 -0
- package/dist/types/options/input-options-schema.d.ts +596 -0
- package/dist/types/options/input-options.d.ts +74 -430
- package/dist/types/options/normalized-input-options.d.ts +17 -11
- package/dist/types/options/normalized-output-options.d.ts +57 -21
- package/dist/types/options/output-options-schema.d.ts +147 -0
- package/dist/types/options/output-options.d.ts +72 -265
- package/dist/types/options/watch-options.d.ts +5 -0
- package/dist/types/plugin/bindingify-build-hooks.d.ts +9 -11
- package/dist/types/plugin/bindingify-hook-filter.d.ts +5 -5
- package/dist/types/plugin/bindingify-output-hooks.d.ts +13 -16
- package/dist/types/plugin/bindingify-plugin.d.ts +12 -3
- package/dist/types/plugin/bindingify-watch-hooks.d.ts +3 -5
- package/dist/types/plugin/hook-filter.d.ts +1 -1
- package/dist/types/plugin/index.d.ts +21 -18
- package/dist/types/plugin/minimal-plugin-context.d.ts +15 -0
- package/dist/types/plugin/plugin-context-data.d.ts +4 -5
- package/dist/types/plugin/plugin-context.d.ts +9 -4
- package/dist/types/plugin/plugin-driver.d.ts +4 -5
- package/dist/types/plugin/transform-plugin-context.d.ts +4 -3
- package/dist/types/rollup-types.d.ts +1 -1
- package/dist/types/treeshake/index.d.ts +0 -12
- package/dist/types/treeshake/module-side-effects.d.ts +111 -11
- package/dist/types/types/rolldown-output.d.ts +11 -2
- package/dist/types/types/utils.d.ts +1 -0
- package/dist/types/utils/bindingify-input-options.d.ts +7 -0
- package/dist/types/utils/bindingify-output-options.d.ts +3 -0
- package/dist/types/utils/define-config.d.ts +3 -0
- package/dist/types/utils/error.d.ts +1 -0
- package/dist/types/utils/normalize-hook.d.ts +1 -1
- package/dist/types/utils/normalize-plugin-option.d.ts +8 -3
- package/dist/types/{options/utils.d.ts → utils/normalize-string-or-regex.d.ts} +1 -1
- package/dist/types/utils/transform-rendered-chunk.d.ts +4 -0
- package/dist/types/utils/transform-rendered-module.d.ts +3 -0
- package/dist/types/utils/transform-sourcemap.d.ts +2 -0
- package/dist/types/utils/transform-to-rollup-output.d.ts +1 -0
- package/package.json +30 -22
- package/dist/shared/rolldown-binding.wasi.cjs +0 -187
- package/dist/shared/src_index-3pqhEViJ.cjs +0 -2785
- package/dist/shared/src_index-ywYMd4vB.mjs +0 -2786
- package/dist/shared/wasi-worker-browser.mjs +0 -39
- package/dist/shared/wasi-worker.mjs +0 -63
- package/dist/shared/watcher-worker.js +0 -1
- package/dist/types/constants/types.d.ts +0 -1
- package/dist/types/options/bindingify-input-options.d.ts +0 -4
- package/dist/types/options/bindingify-output-options.d.ts +0 -3
- package/dist/types/options/normalized-alias-plugin-config.d.ts +0 -8
- package/dist/types/options/watch-option.d.ts +0 -5
- package/dist/types/plugin/builtin-plugin.d.ts +0 -81
- package/dist/types/rolldown-build.d.ts +0 -10
- package/dist/types/rolldown.d.ts +0 -12
- package/dist/types/types/rendered-module.d.ts +0 -2
- package/dist/types/utils/normalize-input-options.d.ts +0 -3
- package/dist/types/utils/normalize-output-options.d.ts +0 -3
- package/dist/types/utils/normalize-tree-shake.d.ts +0 -3
- /package/dist/types/{utils/type-assert.d.ts → types/assert.d.ts} +0 -0
|
@@ -1,431 +1,69 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import { RolldownPluginOption } from '../plugin';
|
|
2
|
+
import { LogLevel, LogLevelOption, LogLevelWithError, RollupLog, RollupLogWithString } from '../log/logging';
|
|
3
3
|
import { TreeshakingOptions } from '../treeshake';
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
export declare const inputOptionsSchema: z.ZodObject<{
|
|
32
|
-
input: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>, z.ZodRecord<z.ZodString, z.ZodString>]>>;
|
|
33
|
-
plugins: z.ZodOptional<z.ZodArray<z.ZodType<RolldownPluginRec, z.ZodTypeDef, RolldownPluginRec>, "many">>;
|
|
34
|
-
external: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, "many">]>, z.ZodFunction<z.ZodTuple<[z.ZodString, z.ZodOptional<z.ZodString>, z.ZodBoolean], z.ZodUnknown>, z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodVoid, z.ZodNull]>, z.ZodUndefined]>, z.ZodBoolean]>>]>>;
|
|
35
|
-
resolve: z.ZodOptional<z.ZodObject<{
|
|
36
|
-
alias: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
37
|
-
aliasFields: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodString, "many">, "many">>;
|
|
38
|
-
conditionNames: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
39
|
-
extensionAlias: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>;
|
|
40
|
-
exportsFields: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodString, "many">, "many">>;
|
|
41
|
-
extensions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
42
|
-
mainFields: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
43
|
-
mainFiles: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
44
|
-
modules: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
45
|
-
symlinks: z.ZodOptional<z.ZodBoolean>;
|
|
46
|
-
tsconfigFilename: z.ZodOptional<z.ZodString>;
|
|
47
|
-
}, "strict", z.ZodTypeAny, {
|
|
48
|
-
alias?: Record<string, string> | undefined;
|
|
49
|
-
aliasFields?: string[][] | undefined;
|
|
50
|
-
conditionNames?: string[] | undefined;
|
|
51
|
-
extensionAlias?: Record<string, string[]> | undefined;
|
|
52
|
-
exportsFields?: string[][] | undefined;
|
|
53
|
-
extensions?: string[] | undefined;
|
|
54
|
-
mainFields?: string[] | undefined;
|
|
55
|
-
mainFiles?: string[] | undefined;
|
|
56
|
-
modules?: string[] | undefined;
|
|
57
|
-
symlinks?: boolean | undefined;
|
|
58
|
-
tsconfigFilename?: string | undefined;
|
|
59
|
-
}, {
|
|
60
|
-
alias?: Record<string, string> | undefined;
|
|
61
|
-
aliasFields?: string[][] | undefined;
|
|
62
|
-
conditionNames?: string[] | undefined;
|
|
63
|
-
extensionAlias?: Record<string, string[]> | undefined;
|
|
64
|
-
exportsFields?: string[][] | undefined;
|
|
65
|
-
extensions?: string[] | undefined;
|
|
66
|
-
mainFields?: string[] | undefined;
|
|
67
|
-
mainFiles?: string[] | undefined;
|
|
68
|
-
modules?: string[] | undefined;
|
|
69
|
-
symlinks?: boolean | undefined;
|
|
70
|
-
tsconfigFilename?: string | undefined;
|
|
71
|
-
}>>;
|
|
72
|
-
cwd: z.ZodOptional<z.ZodString>;
|
|
73
|
-
platform: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"node">, z.ZodLiteral<"browser">]>, z.ZodLiteral<"neutral">]>>;
|
|
74
|
-
shimMissingExports: z.ZodOptional<z.ZodBoolean>;
|
|
75
|
-
treeshake: z.ZodOptional<z.ZodType<boolean | TreeshakingOptions, z.ZodTypeDef, boolean | TreeshakingOptions>>;
|
|
76
|
-
logLevel: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"info">, z.ZodLiteral<"debug">]>, z.ZodLiteral<"warn">]>, z.ZodLiteral<"silent">]>>;
|
|
77
|
-
onLog: z.ZodOptional<z.ZodFunction<z.ZodTuple<[z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"info">, z.ZodLiteral<"debug">]>, z.ZodLiteral<"warn">]>, z.ZodAny, z.ZodFunction<z.ZodTuple<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"info">, z.ZodLiteral<"debug">]>, z.ZodLiteral<"warn">]>, z.ZodLiteral<"error">]>, z.ZodUnion<[z.ZodAny, z.ZodString]>], z.ZodUnknown>, z.ZodUnknown>], z.ZodUnknown>, z.ZodUnknown>>;
|
|
78
|
-
onwarn: z.ZodOptional<z.ZodFunction<z.ZodTuple<[z.ZodAny, z.ZodFunction<z.ZodTuple<[z.ZodUnion<[z.ZodUnion<[z.ZodAny, z.ZodString]>, z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnion<[z.ZodAny, z.ZodString]>>]>], z.ZodUnknown>, z.ZodUnknown>], z.ZodUnknown>, z.ZodUnknown>>;
|
|
79
|
-
moduleTypes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"js">, z.ZodLiteral<"jsx">]>, z.ZodLiteral<"ts">]>, z.ZodLiteral<"tsx">]>, z.ZodLiteral<"json">]>, z.ZodLiteral<"text">]>, z.ZodLiteral<"base64">]>, z.ZodLiteral<"dataurl">]>, z.ZodLiteral<"binary">]>, z.ZodLiteral<"empty">]>, z.ZodLiteral<"css">]>>>;
|
|
80
|
-
experimental: z.ZodOptional<z.ZodObject<{
|
|
81
|
-
enableComposingJsPlugins: z.ZodOptional<z.ZodBoolean>;
|
|
82
|
-
strictExecutionOrder: z.ZodOptional<z.ZodBoolean>;
|
|
83
|
-
disableLiveBindings: z.ZodOptional<z.ZodBoolean>;
|
|
84
|
-
}, "strict", z.ZodTypeAny, {
|
|
85
|
-
enableComposingJsPlugins?: boolean | undefined;
|
|
86
|
-
strictExecutionOrder?: boolean | undefined;
|
|
87
|
-
disableLiveBindings?: boolean | undefined;
|
|
88
|
-
}, {
|
|
89
|
-
enableComposingJsPlugins?: boolean | undefined;
|
|
90
|
-
strictExecutionOrder?: boolean | undefined;
|
|
91
|
-
disableLiveBindings?: boolean | undefined;
|
|
92
|
-
}>>;
|
|
93
|
-
define: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
94
|
-
inject: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodTuple<[z.ZodString, z.ZodString], null>]>>>;
|
|
95
|
-
profilerNames: z.ZodOptional<z.ZodBoolean>;
|
|
96
|
-
jsx: z.ZodOptional<z.ZodObject<{
|
|
97
|
-
mode: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"classic">, z.ZodLiteral<"automatic">]>>;
|
|
98
|
-
factory: z.ZodOptional<z.ZodString>;
|
|
99
|
-
fragment: z.ZodOptional<z.ZodString>;
|
|
100
|
-
importSource: z.ZodOptional<z.ZodString>;
|
|
101
|
-
jsxImportSource: z.ZodOptional<z.ZodString>;
|
|
102
|
-
refresh: z.ZodOptional<z.ZodBoolean>;
|
|
103
|
-
development: z.ZodOptional<z.ZodBoolean>;
|
|
104
|
-
}, "strict", z.ZodTypeAny, {
|
|
105
|
-
mode?: "classic" | "automatic" | undefined;
|
|
106
|
-
factory?: string | undefined;
|
|
107
|
-
fragment?: string | undefined;
|
|
108
|
-
importSource?: string | undefined;
|
|
109
|
-
jsxImportSource?: string | undefined;
|
|
110
|
-
refresh?: boolean | undefined;
|
|
111
|
-
development?: boolean | undefined;
|
|
112
|
-
}, {
|
|
113
|
-
mode?: "classic" | "automatic" | undefined;
|
|
114
|
-
factory?: string | undefined;
|
|
115
|
-
fragment?: string | undefined;
|
|
116
|
-
importSource?: string | undefined;
|
|
117
|
-
jsxImportSource?: string | undefined;
|
|
118
|
-
refresh?: boolean | undefined;
|
|
119
|
-
development?: boolean | undefined;
|
|
120
|
-
}>>;
|
|
121
|
-
watch: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
122
|
-
skipWrite: z.ZodOptional<z.ZodBoolean>;
|
|
123
|
-
notify: z.ZodOptional<z.ZodObject<{
|
|
124
|
-
pollInterval: z.ZodOptional<z.ZodNumber>;
|
|
125
|
-
compareContents: z.ZodOptional<z.ZodBoolean>;
|
|
126
|
-
}, "strict", z.ZodTypeAny, {
|
|
127
|
-
pollInterval?: number | undefined;
|
|
128
|
-
compareContents?: boolean | undefined;
|
|
129
|
-
}, {
|
|
130
|
-
pollInterval?: number | undefined;
|
|
131
|
-
compareContents?: boolean | undefined;
|
|
132
|
-
}>>;
|
|
133
|
-
include: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, "many">]>>;
|
|
134
|
-
exclude: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, "many">]>>;
|
|
135
|
-
chokidar: z.ZodOptional<z.ZodAny>;
|
|
136
|
-
}, "strict", z.ZodTypeAny, {
|
|
137
|
-
skipWrite?: boolean | undefined;
|
|
138
|
-
notify?: {
|
|
139
|
-
pollInterval?: number | undefined;
|
|
140
|
-
compareContents?: boolean | undefined;
|
|
141
|
-
} | undefined;
|
|
142
|
-
include?: string | RegExp | (string | RegExp)[] | undefined;
|
|
143
|
-
exclude?: string | RegExp | (string | RegExp)[] | undefined;
|
|
144
|
-
chokidar?: any;
|
|
145
|
-
}, {
|
|
146
|
-
skipWrite?: boolean | undefined;
|
|
147
|
-
notify?: {
|
|
148
|
-
pollInterval?: number | undefined;
|
|
149
|
-
compareContents?: boolean | undefined;
|
|
150
|
-
} | undefined;
|
|
151
|
-
include?: string | RegExp | (string | RegExp)[] | undefined;
|
|
152
|
-
exclude?: string | RegExp | (string | RegExp)[] | undefined;
|
|
153
|
-
chokidar?: any;
|
|
154
|
-
}>, z.ZodLiteral<false>]>>;
|
|
155
|
-
}, "strict", z.ZodTypeAny, {
|
|
156
|
-
input?: string | string[] | Record<string, string> | undefined;
|
|
157
|
-
plugins?: RolldownPluginRec[] | undefined;
|
|
158
|
-
external?: string | RegExp | (string | RegExp)[] | ((args_0: string, args_1: string | undefined, args_2: boolean, ...args: unknown[]) => boolean | void | null | undefined) | undefined;
|
|
159
|
-
resolve?: {
|
|
160
|
-
alias?: Record<string, string> | undefined;
|
|
161
|
-
aliasFields?: string[][] | undefined;
|
|
162
|
-
conditionNames?: string[] | undefined;
|
|
163
|
-
extensionAlias?: Record<string, string[]> | undefined;
|
|
164
|
-
exportsFields?: string[][] | undefined;
|
|
165
|
-
extensions?: string[] | undefined;
|
|
166
|
-
mainFields?: string[] | undefined;
|
|
167
|
-
mainFiles?: string[] | undefined;
|
|
168
|
-
modules?: string[] | undefined;
|
|
169
|
-
symlinks?: boolean | undefined;
|
|
170
|
-
tsconfigFilename?: string | undefined;
|
|
171
|
-
} | undefined;
|
|
172
|
-
cwd?: string | undefined;
|
|
173
|
-
platform?: "node" | "browser" | "neutral" | undefined;
|
|
174
|
-
shimMissingExports?: boolean | undefined;
|
|
175
|
-
treeshake?: boolean | TreeshakingOptions | undefined;
|
|
176
|
-
logLevel?: "info" | "debug" | "warn" | "silent" | undefined;
|
|
177
|
-
onLog?: ((args_0: "info" | "debug" | "warn", args_1: any, args_2: (args_0: "info" | "debug" | "warn" | "error", args_1: any, ...args: unknown[]) => unknown, ...args: unknown[]) => unknown) | undefined;
|
|
178
|
-
onwarn?: ((args_0: any, args_1: (args_0: any, ...args: unknown[]) => unknown, ...args: unknown[]) => unknown) | undefined;
|
|
179
|
-
jsx?: {
|
|
180
|
-
mode?: "classic" | "automatic" | undefined;
|
|
181
|
-
factory?: string | undefined;
|
|
182
|
-
fragment?: string | undefined;
|
|
183
|
-
importSource?: string | undefined;
|
|
184
|
-
jsxImportSource?: string | undefined;
|
|
185
|
-
refresh?: boolean | undefined;
|
|
186
|
-
development?: boolean | undefined;
|
|
187
|
-
} | undefined;
|
|
188
|
-
moduleTypes?: Record<string, "js" | "jsx" | "ts" | "tsx" | "json" | "text" | "base64" | "dataurl" | "binary" | "empty" | "css"> | undefined;
|
|
189
|
-
experimental?: {
|
|
190
|
-
enableComposingJsPlugins?: boolean | undefined;
|
|
191
|
-
strictExecutionOrder?: boolean | undefined;
|
|
192
|
-
disableLiveBindings?: boolean | undefined;
|
|
193
|
-
} | undefined;
|
|
194
|
-
define?: Record<string, string> | undefined;
|
|
195
|
-
inject?: Record<string, string | [string, string]> | undefined;
|
|
196
|
-
profilerNames?: boolean | undefined;
|
|
197
|
-
watch?: false | {
|
|
198
|
-
skipWrite?: boolean | undefined;
|
|
199
|
-
notify?: {
|
|
200
|
-
pollInterval?: number | undefined;
|
|
201
|
-
compareContents?: boolean | undefined;
|
|
202
|
-
} | undefined;
|
|
203
|
-
include?: string | RegExp | (string | RegExp)[] | undefined;
|
|
204
|
-
exclude?: string | RegExp | (string | RegExp)[] | undefined;
|
|
205
|
-
chokidar?: any;
|
|
206
|
-
} | undefined;
|
|
207
|
-
}, {
|
|
208
|
-
input?: string | string[] | Record<string, string> | undefined;
|
|
209
|
-
plugins?: RolldownPluginRec[] | undefined;
|
|
210
|
-
external?: string | RegExp | (string | RegExp)[] | ((args_0: string, args_1: string | undefined, args_2: boolean, ...args: unknown[]) => boolean | void | null | undefined) | undefined;
|
|
4
|
+
import { NullValue, StringOrRegExp } from '../types/utils';
|
|
5
|
+
export type InputOption = string | string[] | Record<string, string>;
|
|
6
|
+
export type ExternalOption = StringOrRegExp | StringOrRegExp[] | ((id: string, parentId: string | undefined, isResolved: boolean) => NullValue<boolean>);
|
|
7
|
+
export type ModuleTypes = Record<string, 'js' | 'jsx' | 'ts' | 'tsx' | 'json' | 'text' | 'base64' | 'dataurl' | 'binary' | 'empty' | 'css'>;
|
|
8
|
+
export interface JsxOptions {
|
|
9
|
+
mode?: 'classic' | 'automatic';
|
|
10
|
+
factory?: string;
|
|
11
|
+
fragment?: string;
|
|
12
|
+
importSource?: string;
|
|
13
|
+
jsxImportSource?: string;
|
|
14
|
+
refresh?: boolean;
|
|
15
|
+
development?: boolean;
|
|
16
|
+
}
|
|
17
|
+
export interface WatchOptions {
|
|
18
|
+
skipWrite?: boolean;
|
|
19
|
+
notify?: {
|
|
20
|
+
pollInterval?: number;
|
|
21
|
+
compareContents?: boolean;
|
|
22
|
+
};
|
|
23
|
+
include?: StringOrRegExp | StringOrRegExp[];
|
|
24
|
+
exclude?: StringOrRegExp | StringOrRegExp[];
|
|
25
|
+
chokidar?: any;
|
|
26
|
+
}
|
|
27
|
+
export interface InputOptions {
|
|
28
|
+
input?: InputOption;
|
|
29
|
+
plugins?: RolldownPluginOption;
|
|
30
|
+
external?: ExternalOption;
|
|
211
31
|
resolve?: {
|
|
212
|
-
alias?: Record<string, string
|
|
213
|
-
aliasFields?: string[][]
|
|
214
|
-
conditionNames?: string[]
|
|
215
|
-
extensionAlias?: Record<string, string[]
|
|
216
|
-
exportsFields?: string[][]
|
|
217
|
-
extensions?: string[]
|
|
218
|
-
mainFields?: string[]
|
|
219
|
-
mainFiles?: string[]
|
|
220
|
-
modules?: string[]
|
|
221
|
-
symlinks?: boolean
|
|
222
|
-
tsconfigFilename?: string
|
|
223
|
-
}
|
|
224
|
-
cwd?: string
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
} | undefined;
|
|
240
|
-
moduleTypes?: Record<string, "js" | "jsx" | "ts" | "tsx" | "json" | "text" | "base64" | "dataurl" | "binary" | "empty" | "css"> | undefined;
|
|
32
|
+
alias?: Record<string, string>;
|
|
33
|
+
aliasFields?: string[][];
|
|
34
|
+
conditionNames?: string[];
|
|
35
|
+
extensionAlias?: Record<string, string[]>;
|
|
36
|
+
exportsFields?: string[][];
|
|
37
|
+
extensions?: string[];
|
|
38
|
+
mainFields?: string[];
|
|
39
|
+
mainFiles?: string[];
|
|
40
|
+
modules?: string[];
|
|
41
|
+
symlinks?: boolean;
|
|
42
|
+
tsconfigFilename?: string;
|
|
43
|
+
};
|
|
44
|
+
cwd?: string;
|
|
45
|
+
/**
|
|
46
|
+
* Expected platform where the code run.
|
|
47
|
+
*
|
|
48
|
+
* @default
|
|
49
|
+
* - 'node' if the format is 'cjs'
|
|
50
|
+
* - 'browser' for other formats
|
|
51
|
+
*/
|
|
52
|
+
platform?: 'node' | 'browser' | 'neutral';
|
|
53
|
+
shimMissingExports?: boolean;
|
|
54
|
+
treeshake?: boolean | TreeshakingOptions;
|
|
55
|
+
logLevel?: LogLevelOption;
|
|
56
|
+
onLog?: (level: LogLevel, log: RollupLog, defaultHandler: (level: LogLevelWithError, log: RollupLogWithString) => void) => void;
|
|
57
|
+
onwarn?: (warning: RollupLog, defaultHandler: (warning: RollupLogWithString | (() => RollupLogWithString)) => void) => void;
|
|
58
|
+
moduleTypes?: ModuleTypes;
|
|
241
59
|
experimental?: {
|
|
242
|
-
enableComposingJsPlugins?: boolean
|
|
243
|
-
strictExecutionOrder?: boolean
|
|
244
|
-
disableLiveBindings?: boolean
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
watch?: false | {
|
|
250
|
-
skipWrite?: boolean | undefined;
|
|
251
|
-
notify?: {
|
|
252
|
-
pollInterval?: number | undefined;
|
|
253
|
-
compareContents?: boolean | undefined;
|
|
254
|
-
} | undefined;
|
|
255
|
-
include?: string | RegExp | (string | RegExp)[] | undefined;
|
|
256
|
-
exclude?: string | RegExp | (string | RegExp)[] | undefined;
|
|
257
|
-
chokidar?: any;
|
|
258
|
-
} | undefined;
|
|
259
|
-
}>;
|
|
260
|
-
export declare const inputCliOptionsSchema: z.ZodObject<Omit<z.objectUtil.extendShape<{
|
|
261
|
-
input: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>, z.ZodRecord<z.ZodString, z.ZodString>]>>;
|
|
262
|
-
plugins: z.ZodOptional<z.ZodArray<z.ZodType<RolldownPluginRec, z.ZodTypeDef, RolldownPluginRec>, "many">>;
|
|
263
|
-
external: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, "many">]>, z.ZodFunction<z.ZodTuple<[z.ZodString, z.ZodOptional<z.ZodString>, z.ZodBoolean], z.ZodUnknown>, z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodVoid, z.ZodNull]>, z.ZodUndefined]>, z.ZodBoolean]>>]>>;
|
|
264
|
-
resolve: z.ZodOptional<z.ZodObject<{
|
|
265
|
-
alias: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
266
|
-
aliasFields: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodString, "many">, "many">>;
|
|
267
|
-
conditionNames: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
268
|
-
extensionAlias: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>;
|
|
269
|
-
exportsFields: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodString, "many">, "many">>;
|
|
270
|
-
extensions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
271
|
-
mainFields: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
272
|
-
mainFiles: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
273
|
-
modules: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
274
|
-
symlinks: z.ZodOptional<z.ZodBoolean>;
|
|
275
|
-
tsconfigFilename: z.ZodOptional<z.ZodString>;
|
|
276
|
-
}, "strict", z.ZodTypeAny, {
|
|
277
|
-
alias?: Record<string, string> | undefined;
|
|
278
|
-
aliasFields?: string[][] | undefined;
|
|
279
|
-
conditionNames?: string[] | undefined;
|
|
280
|
-
extensionAlias?: Record<string, string[]> | undefined;
|
|
281
|
-
exportsFields?: string[][] | undefined;
|
|
282
|
-
extensions?: string[] | undefined;
|
|
283
|
-
mainFields?: string[] | undefined;
|
|
284
|
-
mainFiles?: string[] | undefined;
|
|
285
|
-
modules?: string[] | undefined;
|
|
286
|
-
symlinks?: boolean | undefined;
|
|
287
|
-
tsconfigFilename?: string | undefined;
|
|
288
|
-
}, {
|
|
289
|
-
alias?: Record<string, string> | undefined;
|
|
290
|
-
aliasFields?: string[][] | undefined;
|
|
291
|
-
conditionNames?: string[] | undefined;
|
|
292
|
-
extensionAlias?: Record<string, string[]> | undefined;
|
|
293
|
-
exportsFields?: string[][] | undefined;
|
|
294
|
-
extensions?: string[] | undefined;
|
|
295
|
-
mainFields?: string[] | undefined;
|
|
296
|
-
mainFiles?: string[] | undefined;
|
|
297
|
-
modules?: string[] | undefined;
|
|
298
|
-
symlinks?: boolean | undefined;
|
|
299
|
-
tsconfigFilename?: string | undefined;
|
|
300
|
-
}>>;
|
|
301
|
-
cwd: z.ZodOptional<z.ZodString>;
|
|
302
|
-
platform: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"node">, z.ZodLiteral<"browser">]>, z.ZodLiteral<"neutral">]>>;
|
|
303
|
-
shimMissingExports: z.ZodOptional<z.ZodBoolean>;
|
|
304
|
-
treeshake: z.ZodOptional<z.ZodType<boolean | TreeshakingOptions, z.ZodTypeDef, boolean | TreeshakingOptions>>;
|
|
305
|
-
logLevel: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"info">, z.ZodLiteral<"debug">]>, z.ZodLiteral<"warn">]>, z.ZodLiteral<"silent">]>>;
|
|
306
|
-
onLog: z.ZodOptional<z.ZodFunction<z.ZodTuple<[z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"info">, z.ZodLiteral<"debug">]>, z.ZodLiteral<"warn">]>, z.ZodAny, z.ZodFunction<z.ZodTuple<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"info">, z.ZodLiteral<"debug">]>, z.ZodLiteral<"warn">]>, z.ZodLiteral<"error">]>, z.ZodUnion<[z.ZodAny, z.ZodString]>], z.ZodUnknown>, z.ZodUnknown>], z.ZodUnknown>, z.ZodUnknown>>;
|
|
307
|
-
onwarn: z.ZodOptional<z.ZodFunction<z.ZodTuple<[z.ZodAny, z.ZodFunction<z.ZodTuple<[z.ZodUnion<[z.ZodUnion<[z.ZodAny, z.ZodString]>, z.ZodFunction<z.ZodTuple<[], z.ZodUnknown>, z.ZodUnion<[z.ZodAny, z.ZodString]>>]>], z.ZodUnknown>, z.ZodUnknown>], z.ZodUnknown>, z.ZodUnknown>>;
|
|
308
|
-
moduleTypes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodUnion<[z.ZodLiteral<"js">, z.ZodLiteral<"jsx">]>, z.ZodLiteral<"ts">]>, z.ZodLiteral<"tsx">]>, z.ZodLiteral<"json">]>, z.ZodLiteral<"text">]>, z.ZodLiteral<"base64">]>, z.ZodLiteral<"dataurl">]>, z.ZodLiteral<"binary">]>, z.ZodLiteral<"empty">]>, z.ZodLiteral<"css">]>>>;
|
|
309
|
-
experimental: z.ZodOptional<z.ZodObject<{
|
|
310
|
-
enableComposingJsPlugins: z.ZodOptional<z.ZodBoolean>;
|
|
311
|
-
strictExecutionOrder: z.ZodOptional<z.ZodBoolean>;
|
|
312
|
-
disableLiveBindings: z.ZodOptional<z.ZodBoolean>;
|
|
313
|
-
}, "strict", z.ZodTypeAny, {
|
|
314
|
-
enableComposingJsPlugins?: boolean | undefined;
|
|
315
|
-
strictExecutionOrder?: boolean | undefined;
|
|
316
|
-
disableLiveBindings?: boolean | undefined;
|
|
317
|
-
}, {
|
|
318
|
-
enableComposingJsPlugins?: boolean | undefined;
|
|
319
|
-
strictExecutionOrder?: boolean | undefined;
|
|
320
|
-
disableLiveBindings?: boolean | undefined;
|
|
321
|
-
}>>;
|
|
322
|
-
define: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
323
|
-
inject: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodTuple<[z.ZodString, z.ZodString], null>]>>>;
|
|
324
|
-
profilerNames: z.ZodOptional<z.ZodBoolean>;
|
|
325
|
-
jsx: z.ZodOptional<z.ZodObject<{
|
|
326
|
-
mode: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"classic">, z.ZodLiteral<"automatic">]>>;
|
|
327
|
-
factory: z.ZodOptional<z.ZodString>;
|
|
328
|
-
fragment: z.ZodOptional<z.ZodString>;
|
|
329
|
-
importSource: z.ZodOptional<z.ZodString>;
|
|
330
|
-
jsxImportSource: z.ZodOptional<z.ZodString>;
|
|
331
|
-
refresh: z.ZodOptional<z.ZodBoolean>;
|
|
332
|
-
development: z.ZodOptional<z.ZodBoolean>;
|
|
333
|
-
}, "strict", z.ZodTypeAny, {
|
|
334
|
-
mode?: "classic" | "automatic" | undefined;
|
|
335
|
-
factory?: string | undefined;
|
|
336
|
-
fragment?: string | undefined;
|
|
337
|
-
importSource?: string | undefined;
|
|
338
|
-
jsxImportSource?: string | undefined;
|
|
339
|
-
refresh?: boolean | undefined;
|
|
340
|
-
development?: boolean | undefined;
|
|
341
|
-
}, {
|
|
342
|
-
mode?: "classic" | "automatic" | undefined;
|
|
343
|
-
factory?: string | undefined;
|
|
344
|
-
fragment?: string | undefined;
|
|
345
|
-
importSource?: string | undefined;
|
|
346
|
-
jsxImportSource?: string | undefined;
|
|
347
|
-
refresh?: boolean | undefined;
|
|
348
|
-
development?: boolean | undefined;
|
|
349
|
-
}>>;
|
|
350
|
-
watch: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
351
|
-
skipWrite: z.ZodOptional<z.ZodBoolean>;
|
|
352
|
-
notify: z.ZodOptional<z.ZodObject<{
|
|
353
|
-
pollInterval: z.ZodOptional<z.ZodNumber>;
|
|
354
|
-
compareContents: z.ZodOptional<z.ZodBoolean>;
|
|
355
|
-
}, "strict", z.ZodTypeAny, {
|
|
356
|
-
pollInterval?: number | undefined;
|
|
357
|
-
compareContents?: boolean | undefined;
|
|
358
|
-
}, {
|
|
359
|
-
pollInterval?: number | undefined;
|
|
360
|
-
compareContents?: boolean | undefined;
|
|
361
|
-
}>>;
|
|
362
|
-
include: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, "many">]>>;
|
|
363
|
-
exclude: z.ZodOptional<z.ZodUnion<[z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodType<RegExp, z.ZodTypeDef, RegExp>]>, "many">]>>;
|
|
364
|
-
chokidar: z.ZodOptional<z.ZodAny>;
|
|
365
|
-
}, "strict", z.ZodTypeAny, {
|
|
366
|
-
skipWrite?: boolean | undefined;
|
|
367
|
-
notify?: {
|
|
368
|
-
pollInterval?: number | undefined;
|
|
369
|
-
compareContents?: boolean | undefined;
|
|
370
|
-
} | undefined;
|
|
371
|
-
include?: string | RegExp | (string | RegExp)[] | undefined;
|
|
372
|
-
exclude?: string | RegExp | (string | RegExp)[] | undefined;
|
|
373
|
-
chokidar?: any;
|
|
374
|
-
}, {
|
|
375
|
-
skipWrite?: boolean | undefined;
|
|
376
|
-
notify?: {
|
|
377
|
-
pollInterval?: number | undefined;
|
|
378
|
-
compareContents?: boolean | undefined;
|
|
379
|
-
} | undefined;
|
|
380
|
-
include?: string | RegExp | (string | RegExp)[] | undefined;
|
|
381
|
-
exclude?: string | RegExp | (string | RegExp)[] | undefined;
|
|
382
|
-
chokidar?: any;
|
|
383
|
-
}>, z.ZodLiteral<false>]>>;
|
|
384
|
-
}, {
|
|
385
|
-
external: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
386
|
-
inject: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
387
|
-
treeshake: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
388
|
-
}>, "input" | "plugins" | "resolve" | "onLog" | "onwarn" | "experimental" | "profilerNames" | "watch">, "strict", z.ZodTypeAny, {
|
|
389
|
-
external?: string[] | undefined;
|
|
390
|
-
cwd?: string | undefined;
|
|
391
|
-
platform?: "node" | "browser" | "neutral" | undefined;
|
|
392
|
-
shimMissingExports?: boolean | undefined;
|
|
393
|
-
treeshake?: boolean | undefined;
|
|
394
|
-
logLevel?: "info" | "debug" | "warn" | "silent" | undefined;
|
|
395
|
-
jsx?: {
|
|
396
|
-
mode?: "classic" | "automatic" | undefined;
|
|
397
|
-
factory?: string | undefined;
|
|
398
|
-
fragment?: string | undefined;
|
|
399
|
-
importSource?: string | undefined;
|
|
400
|
-
jsxImportSource?: string | undefined;
|
|
401
|
-
refresh?: boolean | undefined;
|
|
402
|
-
development?: boolean | undefined;
|
|
403
|
-
} | undefined;
|
|
404
|
-
moduleTypes?: Record<string, "js" | "jsx" | "ts" | "tsx" | "json" | "text" | "base64" | "dataurl" | "binary" | "empty" | "css"> | undefined;
|
|
405
|
-
define?: Record<string, string> | undefined;
|
|
406
|
-
inject?: Record<string, string> | undefined;
|
|
407
|
-
}, {
|
|
408
|
-
external?: string[] | undefined;
|
|
409
|
-
cwd?: string | undefined;
|
|
410
|
-
platform?: "node" | "browser" | "neutral" | undefined;
|
|
411
|
-
shimMissingExports?: boolean | undefined;
|
|
412
|
-
treeshake?: boolean | undefined;
|
|
413
|
-
logLevel?: "info" | "debug" | "warn" | "silent" | undefined;
|
|
414
|
-
jsx?: {
|
|
415
|
-
mode?: "classic" | "automatic" | undefined;
|
|
416
|
-
factory?: string | undefined;
|
|
417
|
-
fragment?: string | undefined;
|
|
418
|
-
importSource?: string | undefined;
|
|
419
|
-
jsxImportSource?: string | undefined;
|
|
420
|
-
refresh?: boolean | undefined;
|
|
421
|
-
development?: boolean | undefined;
|
|
422
|
-
} | undefined;
|
|
423
|
-
moduleTypes?: Record<string, "js" | "jsx" | "ts" | "tsx" | "json" | "text" | "base64" | "dataurl" | "binary" | "empty" | "css"> | undefined;
|
|
424
|
-
define?: Record<string, string> | undefined;
|
|
425
|
-
inject?: Record<string, string> | undefined;
|
|
426
|
-
}>;
|
|
427
|
-
type RawInputOptions = z.infer<typeof inputOptionsSchema>;
|
|
428
|
-
interface OverwriteInputOptionsWithDoc {
|
|
60
|
+
enableComposingJsPlugins?: boolean;
|
|
61
|
+
strictExecutionOrder?: boolean;
|
|
62
|
+
disableLiveBindings?: boolean;
|
|
63
|
+
viteMode?: boolean;
|
|
64
|
+
resolveNewUrlToAsset?: boolean;
|
|
65
|
+
};
|
|
66
|
+
define?: Record<string, string>;
|
|
429
67
|
/**
|
|
430
68
|
* Inject import statements on demand.
|
|
431
69
|
*
|
|
@@ -449,10 +87,16 @@ interface OverwriteInputOptionsWithDoc {
|
|
|
449
87
|
* }
|
|
450
88
|
* ```
|
|
451
89
|
*/
|
|
452
|
-
inject?:
|
|
90
|
+
inject?: Record<string, string | [string, string]>;
|
|
91
|
+
profilerNames?: boolean;
|
|
92
|
+
jsx?: JsxOptions;
|
|
93
|
+
watch?: WatchOptions | false;
|
|
94
|
+
dropLabels?: string[];
|
|
95
|
+
}
|
|
96
|
+
interface OverwriteInputOptionsForCli {
|
|
97
|
+
external?: string[];
|
|
98
|
+
inject?: Record<string, string>;
|
|
99
|
+
treeshake?: boolean;
|
|
453
100
|
}
|
|
454
|
-
export type
|
|
455
|
-
export type InputOptions = Omit<RawInputOptions, keyof OverwriteInputOptionsWithDoc> & OverwriteInputOptionsWithDoc;
|
|
456
|
-
export type ExternalOption = z.infer<typeof externalSchema>;
|
|
457
|
-
export type JsxOptions = z.infer<typeof jsxOptionsSchema>;
|
|
101
|
+
export type InputCliOptions = Omit<InputOptions, keyof OverwriteInputOptionsForCli | 'input' | 'plugins' | 'onwarn' | 'onLog' | 'resolve' | 'experimental' | 'profilerNames' | 'watch'> & OverwriteInputOptionsForCli;
|
|
458
102
|
export {};
|
|
@@ -1,12 +1,18 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
import type { LogHandler } from '../rollup';
|
|
2
|
+
import { BindingNormalizedOptions } from '../binding';
|
|
3
|
+
import { InputOptions } from '..';
|
|
4
|
+
export interface NormalizedInputOptions {
|
|
5
|
+
input: string[] | Record<string, string>;
|
|
6
|
+
cwd: string | undefined;
|
|
7
|
+
platform: InputOptions['platform'];
|
|
8
|
+
shimMissingExports: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare class NormalizedInputOptionsImpl implements NormalizedInputOptions {
|
|
11
|
+
onLog: LogHandler;
|
|
12
|
+
inner: BindingNormalizedOptions;
|
|
13
|
+
constructor(inner: BindingNormalizedOptions, onLog: LogHandler);
|
|
14
|
+
get shimMissingExports(): boolean;
|
|
15
|
+
get input(): string[] | Record<string, string>;
|
|
16
|
+
get cwd(): string | undefined;
|
|
17
|
+
get platform(): "node" | "browser" | "neutral";
|
|
12
18
|
}
|
|
@@ -1,27 +1,63 @@
|
|
|
1
|
+
import type { BindingNormalizedOptions } from '../binding';
|
|
1
2
|
import type { SourcemapIgnoreListOption, SourcemapPathTransformOption } from '../rollup';
|
|
2
|
-
import type { OutputOptions } from './output-options';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
type ChunkFileNamesOption = string | ((chunk: PreRenderedChunk) => string) | undefined;
|
|
8
|
-
export interface NormalizedOutputOptions extends OutputOptions {
|
|
9
|
-
plugins: RolldownPlugin[];
|
|
3
|
+
import type { ChunkFileNamesFunction, GlobalsFunction, OutputOptions } from './output-options';
|
|
4
|
+
export type InternalModuleFormat = 'es' | 'cjs' | 'iife' | 'umd' | 'app';
|
|
5
|
+
export interface NormalizedOutputOptions {
|
|
6
|
+
name: string | undefined;
|
|
7
|
+
file: string | undefined;
|
|
10
8
|
dir: string | undefined;
|
|
9
|
+
entryFileNames: string | ChunkFileNamesFunction;
|
|
10
|
+
chunkFileNames: string | ChunkFileNamesFunction;
|
|
11
|
+
assetFileNames: string;
|
|
11
12
|
format: InternalModuleFormat;
|
|
12
|
-
exports: '
|
|
13
|
+
exports: NonNullable<OutputOptions['exports']>;
|
|
13
14
|
sourcemap: boolean | 'inline' | 'hidden';
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
banner: AddonFunction;
|
|
17
|
-
footer: AddonFunction;
|
|
18
|
-
intro: AddonFunction;
|
|
19
|
-
outro: AddonFunction;
|
|
20
|
-
esModule: boolean | 'if-default-prop';
|
|
21
|
-
entryFileNames: ChunkFileNamesOption;
|
|
22
|
-
chunkFileNames: ChunkFileNamesOption;
|
|
23
|
-
assetFileNames: string;
|
|
24
|
-
name: string | undefined;
|
|
15
|
+
cssEntryFileNames: string | ChunkFileNamesFunction;
|
|
16
|
+
cssChunkFileNames: string | ChunkFileNamesFunction;
|
|
25
17
|
inlineDynamicImports: boolean;
|
|
18
|
+
externalLiveBindings: boolean;
|
|
19
|
+
banner: OutputOptions['banner'];
|
|
20
|
+
footer: OutputOptions['footer'];
|
|
21
|
+
intro: OutputOptions['intro'];
|
|
22
|
+
outro: OutputOptions['outro'];
|
|
23
|
+
esModule: boolean | 'if-default-prop';
|
|
24
|
+
extend: boolean;
|
|
25
|
+
globals: Record<string, string> | GlobalsFunction;
|
|
26
|
+
hashCharacters: 'base64' | 'base36' | 'hex';
|
|
27
|
+
sourcemapDebugIds: boolean;
|
|
28
|
+
sourcemapIgnoreList: SourcemapIgnoreListOption | undefined;
|
|
29
|
+
sourcemapPathTransform: SourcemapPathTransformOption | undefined;
|
|
30
|
+
minify: boolean;
|
|
31
|
+
comments: 'none' | 'preserve-legal';
|
|
32
|
+
}
|
|
33
|
+
export declare class NormalizedOutputOptionsImpl implements NormalizedOutputOptions {
|
|
34
|
+
inner: BindingNormalizedOptions;
|
|
35
|
+
constructor(inner: BindingNormalizedOptions);
|
|
36
|
+
get dir(): string | undefined;
|
|
37
|
+
get entryFileNames(): string | (() => never);
|
|
38
|
+
get chunkFileNames(): string | (() => never);
|
|
39
|
+
get assetFileNames(): string;
|
|
40
|
+
get format(): "es" | "cjs" | "iife" | "umd" | "app";
|
|
41
|
+
get exports(): "auto" | "named" | "default" | "none";
|
|
42
|
+
get sourcemap(): boolean | "inline" | "hidden";
|
|
43
|
+
get cssEntryFileNames(): string | (() => never);
|
|
44
|
+
get cssChunkFileNames(): string | (() => never);
|
|
45
|
+
get shimMissingExports(): boolean;
|
|
46
|
+
get name(): string | undefined;
|
|
47
|
+
get file(): string | undefined;
|
|
48
|
+
get inlineDynamicImports(): boolean;
|
|
49
|
+
get externalLiveBindings(): boolean;
|
|
50
|
+
get banner(): string | (() => never) | undefined;
|
|
51
|
+
get footer(): string | (() => never) | undefined;
|
|
52
|
+
get intro(): string | (() => never) | undefined;
|
|
53
|
+
get outro(): string | (() => never) | undefined;
|
|
54
|
+
get esModule(): boolean | "if-default-prop";
|
|
55
|
+
get extend(): boolean;
|
|
56
|
+
get globals(): Record<string, string> | (() => never);
|
|
57
|
+
get hashCharacters(): "base64" | "base36" | "hex";
|
|
58
|
+
get sourcemapDebugIds(): boolean;
|
|
59
|
+
get sourcemapIgnoreList(): (() => never) | undefined;
|
|
60
|
+
get sourcemapPathTransform(): (() => never) | undefined;
|
|
61
|
+
get minify(): boolean;
|
|
62
|
+
get comments(): "none" | "preserve-legal";
|
|
26
63
|
}
|
|
27
|
-
export {};
|