vize 0.89.0 → 0.91.0
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/{config-CTXni-Py.d.mts → config-XMCb6V8W.d.mts} +224 -215
- package/dist/config-XMCb6V8W.d.mts.map +1 -0
- package/dist/config.d.mts +1 -1
- package/dist/config.mjs +80 -50
- package/dist/config.mjs.map +1 -1
- package/dist/index.d.mts +2 -2
- package/package.json +11 -10
- package/pkl/CompilerConfig.pkl +37 -0
- package/pkl/FormatterConfig.pkl +67 -0
- package/pkl/GlobalTypesConfig.pkl +15 -0
- package/pkl/LanguageServerConfig.pkl +70 -0
- package/pkl/LinterConfig.pkl +17 -0
- package/pkl/LspConfig.pkl +6 -0
- package/pkl/MuseaConfig.pkl +38 -0
- package/pkl/PklProject +16 -0
- package/pkl/PklProject.deps.json +19 -0
- package/pkl/TypeCheckerConfig.pkl +43 -0
- package/pkl/VitePluginConfig.pkl +20 -0
- package/pkl/VizeConfig.pkl +55 -0
- package/pkl/jsonschema/generate.pkl +622 -0
- package/pkl/vize.pkl +12 -1
- package/schemas/vize.config.schema.json +375 -126
- package/src/config.ts +120 -51
- package/src/index.ts +1 -0
- package/src/types/generated.ts +472 -0
- package/src/types/index.ts +19 -10
- package/src/types/rules.ts +1 -1
- package/src/types/{loader.ts → runtime.ts} +15 -20
- package/dist/config-CTXni-Py.d.mts.map +0 -1
- package/src/types/compiler.ts +0 -121
- package/src/types/core.ts +0 -83
- package/src/types/musea.ts +0 -108
- package/src/types/tools.ts +0 -266
|
@@ -0,0 +1,472 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
/**
|
|
3
|
+
* This file was automatically generated by json-schema-to-typescript.
|
|
4
|
+
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
|
|
5
|
+
* and run json-schema-to-typescript to regenerate this file.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
export type LintPreset = "happy-path" | "opinionated" | "essential" | "incremental" | "nuxt";
|
|
9
|
+
|
|
10
|
+
export type RuleSeverity = "off" | "warn" | "error";
|
|
11
|
+
|
|
12
|
+
export type RuleCategory = "correctness" | "suspicious" | "style" | "perf" | "a11y" | "security";
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Configuration file for vize - High-performance Vue.js toolchain
|
|
16
|
+
*/
|
|
17
|
+
export interface VizeConfig {
|
|
18
|
+
compiler?: CompilerConfig;
|
|
19
|
+
vite?: VitePluginConfig;
|
|
20
|
+
linter?: LinterConfig;
|
|
21
|
+
typeChecker?: TypeCheckerConfig;
|
|
22
|
+
formatter?: FormatterConfig;
|
|
23
|
+
languageServer?: LanguageServerConfig;
|
|
24
|
+
lsp?: LanguageServerConfig;
|
|
25
|
+
musea?: MuseaConfig;
|
|
26
|
+
globalTypes?: GlobalTypesConfig;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Vue compiler options
|
|
30
|
+
*/
|
|
31
|
+
export interface CompilerConfig {
|
|
32
|
+
/**
|
|
33
|
+
* Compilation mode
|
|
34
|
+
*/
|
|
35
|
+
mode?: "module" | "function";
|
|
36
|
+
/**
|
|
37
|
+
* Enable Vapor mode compilation
|
|
38
|
+
*/
|
|
39
|
+
vapor?: boolean;
|
|
40
|
+
/**
|
|
41
|
+
* Enable SSR mode
|
|
42
|
+
*/
|
|
43
|
+
ssr?: boolean;
|
|
44
|
+
/**
|
|
45
|
+
* Enable source map generation
|
|
46
|
+
*/
|
|
47
|
+
sourceMap?: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Prefix template identifiers with _ctx
|
|
50
|
+
*/
|
|
51
|
+
prefixIdentifiers?: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* Hoist static nodes
|
|
54
|
+
*/
|
|
55
|
+
hoistStatic?: boolean;
|
|
56
|
+
/**
|
|
57
|
+
* Cache v-on handlers
|
|
58
|
+
*/
|
|
59
|
+
cacheHandlers?: boolean;
|
|
60
|
+
/**
|
|
61
|
+
* Enable TypeScript parsing in <script> blocks
|
|
62
|
+
*/
|
|
63
|
+
isTs?: boolean;
|
|
64
|
+
/**
|
|
65
|
+
* Script file extension for generated output
|
|
66
|
+
*/
|
|
67
|
+
scriptExt?: "ts" | "js";
|
|
68
|
+
/**
|
|
69
|
+
* Module name for runtime imports
|
|
70
|
+
*/
|
|
71
|
+
runtimeModuleName?: string;
|
|
72
|
+
/**
|
|
73
|
+
* Global variable name for runtime (IIFE builds)
|
|
74
|
+
*/
|
|
75
|
+
runtimeGlobalName?: string;
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Vite plugin options
|
|
79
|
+
*/
|
|
80
|
+
export interface VitePluginConfig {
|
|
81
|
+
/**
|
|
82
|
+
* Files to include in compilation (glob patterns or strings)
|
|
83
|
+
*/
|
|
84
|
+
include?: string | RegExp | (string | RegExp)[];
|
|
85
|
+
/**
|
|
86
|
+
* Files to exclude from compilation (glob patterns or strings)
|
|
87
|
+
*/
|
|
88
|
+
exclude?: string | RegExp | (string | RegExp)[];
|
|
89
|
+
/**
|
|
90
|
+
* Glob patterns to scan for .vue files during pre-compilation
|
|
91
|
+
*/
|
|
92
|
+
scanPatterns?: string[];
|
|
93
|
+
/**
|
|
94
|
+
* Glob patterns to ignore during pre-compilation
|
|
95
|
+
*/
|
|
96
|
+
ignorePatterns?: string[];
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* Linter options
|
|
100
|
+
*/
|
|
101
|
+
export interface LinterConfig {
|
|
102
|
+
/**
|
|
103
|
+
* Enable linting
|
|
104
|
+
*/
|
|
105
|
+
enabled?: boolean;
|
|
106
|
+
/**
|
|
107
|
+
* Built-in lint preset
|
|
108
|
+
*/
|
|
109
|
+
preset?: "happy-path" | "opinionated" | "essential" | "incremental" | "nuxt";
|
|
110
|
+
/**
|
|
111
|
+
* Rules to enable/disable
|
|
112
|
+
*/
|
|
113
|
+
rules?: {
|
|
114
|
+
[k: string]: "off" | "warn" | "error";
|
|
115
|
+
};
|
|
116
|
+
/**
|
|
117
|
+
* Category-level severity overrides
|
|
118
|
+
*/
|
|
119
|
+
categories?: {
|
|
120
|
+
correctness?: "off" | "warn" | "error";
|
|
121
|
+
suspicious?: "off" | "warn" | "error";
|
|
122
|
+
style?: "off" | "warn" | "error";
|
|
123
|
+
perf?: "off" | "warn" | "error";
|
|
124
|
+
a11y?: "off" | "warn" | "error";
|
|
125
|
+
security?: "off" | "warn" | "error";
|
|
126
|
+
};
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Type checker options
|
|
130
|
+
*/
|
|
131
|
+
export interface TypeCheckerConfig {
|
|
132
|
+
/**
|
|
133
|
+
* Enable type checking
|
|
134
|
+
*/
|
|
135
|
+
enabled?: boolean;
|
|
136
|
+
/**
|
|
137
|
+
* Enable strict mode
|
|
138
|
+
*/
|
|
139
|
+
strict?: boolean;
|
|
140
|
+
/**
|
|
141
|
+
* Check component props
|
|
142
|
+
*/
|
|
143
|
+
checkProps?: boolean;
|
|
144
|
+
/**
|
|
145
|
+
* Check component emits
|
|
146
|
+
*/
|
|
147
|
+
checkEmits?: boolean;
|
|
148
|
+
/**
|
|
149
|
+
* Check template bindings
|
|
150
|
+
*/
|
|
151
|
+
checkTemplateBindings?: boolean;
|
|
152
|
+
/**
|
|
153
|
+
* Check reactivity loss patterns
|
|
154
|
+
*/
|
|
155
|
+
checkReactivity?: boolean;
|
|
156
|
+
/**
|
|
157
|
+
* Check setup context violations
|
|
158
|
+
*/
|
|
159
|
+
checkSetupContext?: boolean;
|
|
160
|
+
/**
|
|
161
|
+
* Check invalid exports in <script setup>
|
|
162
|
+
*/
|
|
163
|
+
checkInvalidExports?: boolean;
|
|
164
|
+
/**
|
|
165
|
+
* Check fallthrough attrs on multi-root templates
|
|
166
|
+
*/
|
|
167
|
+
checkFallthroughAttrs?: boolean;
|
|
168
|
+
/**
|
|
169
|
+
* Path to tsconfig.json
|
|
170
|
+
*/
|
|
171
|
+
tsconfig?: string;
|
|
172
|
+
/**
|
|
173
|
+
* Path to tsgo binary
|
|
174
|
+
*/
|
|
175
|
+
tsgoPath?: string;
|
|
176
|
+
/**
|
|
177
|
+
* Path to a .d.ts file that declares template globals
|
|
178
|
+
*/
|
|
179
|
+
globalsFile?: string;
|
|
180
|
+
/**
|
|
181
|
+
* Number of parallel Corsa servers to use
|
|
182
|
+
*/
|
|
183
|
+
servers?: number;
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
* Formatter options
|
|
187
|
+
*/
|
|
188
|
+
export interface FormatterConfig {
|
|
189
|
+
/**
|
|
190
|
+
* Max line width
|
|
191
|
+
*/
|
|
192
|
+
printWidth?: number;
|
|
193
|
+
/**
|
|
194
|
+
* Indentation width
|
|
195
|
+
*/
|
|
196
|
+
tabWidth?: number;
|
|
197
|
+
/**
|
|
198
|
+
* Use tabs for indentation
|
|
199
|
+
*/
|
|
200
|
+
useTabs?: boolean;
|
|
201
|
+
/**
|
|
202
|
+
* Print semicolons
|
|
203
|
+
*/
|
|
204
|
+
semi?: boolean;
|
|
205
|
+
/**
|
|
206
|
+
* Use single quotes
|
|
207
|
+
*/
|
|
208
|
+
singleQuote?: boolean;
|
|
209
|
+
/**
|
|
210
|
+
* Use single quotes in JSX
|
|
211
|
+
*/
|
|
212
|
+
jsxSingleQuote?: boolean;
|
|
213
|
+
/**
|
|
214
|
+
* Trailing commas
|
|
215
|
+
*/
|
|
216
|
+
trailingComma?: "all" | "none" | "es5";
|
|
217
|
+
/**
|
|
218
|
+
* Print spaces between brackets in object literals
|
|
219
|
+
*/
|
|
220
|
+
bracketSpacing?: boolean;
|
|
221
|
+
/**
|
|
222
|
+
* Keep > on the last line of multiline tags
|
|
223
|
+
*/
|
|
224
|
+
bracketSameLine?: boolean;
|
|
225
|
+
/**
|
|
226
|
+
* Arrow parens mode
|
|
227
|
+
*/
|
|
228
|
+
arrowParens?: "always" | "avoid";
|
|
229
|
+
/**
|
|
230
|
+
* End-of-line mode
|
|
231
|
+
*/
|
|
232
|
+
endOfLine?: "lf" | "crlf" | "cr" | "auto";
|
|
233
|
+
/**
|
|
234
|
+
* Object property quoting mode
|
|
235
|
+
*/
|
|
236
|
+
quoteProps?: "as-needed" | "consistent" | "preserve";
|
|
237
|
+
/**
|
|
238
|
+
* Force one attribute per line
|
|
239
|
+
*/
|
|
240
|
+
singleAttributePerLine?: boolean;
|
|
241
|
+
/**
|
|
242
|
+
* Indent script and style blocks
|
|
243
|
+
*/
|
|
244
|
+
vueIndentScriptAndStyle?: boolean;
|
|
245
|
+
/**
|
|
246
|
+
* Sort attributes
|
|
247
|
+
*/
|
|
248
|
+
sortAttributes?: boolean;
|
|
249
|
+
/**
|
|
250
|
+
* Attribute ordering strategy
|
|
251
|
+
*/
|
|
252
|
+
attributeSortOrder?: "alphabetical" | "as-written";
|
|
253
|
+
/**
|
|
254
|
+
* Merge bind and non-bind attrs for sorting
|
|
255
|
+
*/
|
|
256
|
+
mergeBindAndNonBindAttrs?: boolean;
|
|
257
|
+
/**
|
|
258
|
+
* Maximum attributes per line before wrapping
|
|
259
|
+
*/
|
|
260
|
+
maxAttributesPerLine?: number;
|
|
261
|
+
/**
|
|
262
|
+
* Custom attribute groups
|
|
263
|
+
*/
|
|
264
|
+
attributeGroups?: string[][];
|
|
265
|
+
/**
|
|
266
|
+
* Normalize directive shorthands
|
|
267
|
+
*/
|
|
268
|
+
normalizeDirectiveShorthands?: boolean;
|
|
269
|
+
/**
|
|
270
|
+
* Sort SFC blocks in canonical order
|
|
271
|
+
*/
|
|
272
|
+
sortBlocks?: boolean;
|
|
273
|
+
}
|
|
274
|
+
/**
|
|
275
|
+
* Language server options
|
|
276
|
+
*/
|
|
277
|
+
export interface LanguageServerConfig {
|
|
278
|
+
/**
|
|
279
|
+
* Enable the language server
|
|
280
|
+
*/
|
|
281
|
+
enabled?: boolean;
|
|
282
|
+
/**
|
|
283
|
+
* Enable lint diagnostics
|
|
284
|
+
*/
|
|
285
|
+
lint?: boolean;
|
|
286
|
+
/**
|
|
287
|
+
* Deprecated alias for lint
|
|
288
|
+
*/
|
|
289
|
+
diagnostics?: boolean;
|
|
290
|
+
/**
|
|
291
|
+
* Enable project type checking diagnostics
|
|
292
|
+
*/
|
|
293
|
+
typecheck?: boolean;
|
|
294
|
+
/**
|
|
295
|
+
* Enable editor-oriented IDE features
|
|
296
|
+
*/
|
|
297
|
+
editor?: boolean;
|
|
298
|
+
/**
|
|
299
|
+
* Enable completions
|
|
300
|
+
*/
|
|
301
|
+
completion?: boolean;
|
|
302
|
+
/**
|
|
303
|
+
* Enable hover information
|
|
304
|
+
*/
|
|
305
|
+
hover?: boolean;
|
|
306
|
+
/**
|
|
307
|
+
* Enable go-to-definition
|
|
308
|
+
*/
|
|
309
|
+
definition?: boolean;
|
|
310
|
+
/**
|
|
311
|
+
* Enable reference search
|
|
312
|
+
*/
|
|
313
|
+
references?: boolean;
|
|
314
|
+
/**
|
|
315
|
+
* Enable document symbols
|
|
316
|
+
*/
|
|
317
|
+
documentSymbols?: boolean;
|
|
318
|
+
/**
|
|
319
|
+
* Enable workspace symbols
|
|
320
|
+
*/
|
|
321
|
+
workspaceSymbols?: boolean;
|
|
322
|
+
/**
|
|
323
|
+
* Enable formatting via the language server
|
|
324
|
+
*/
|
|
325
|
+
formatting?: boolean;
|
|
326
|
+
/**
|
|
327
|
+
* Enable code actions
|
|
328
|
+
*/
|
|
329
|
+
codeActions?: boolean;
|
|
330
|
+
/**
|
|
331
|
+
* Enable rename support
|
|
332
|
+
*/
|
|
333
|
+
rename?: boolean;
|
|
334
|
+
/**
|
|
335
|
+
* Enable code lenses
|
|
336
|
+
*/
|
|
337
|
+
codeLens?: boolean;
|
|
338
|
+
/**
|
|
339
|
+
* Enable semantic tokens
|
|
340
|
+
*/
|
|
341
|
+
semanticTokens?: boolean;
|
|
342
|
+
/**
|
|
343
|
+
* Enable document links
|
|
344
|
+
*/
|
|
345
|
+
documentLinks?: boolean;
|
|
346
|
+
/**
|
|
347
|
+
* Enable folding ranges
|
|
348
|
+
*/
|
|
349
|
+
foldingRanges?: boolean;
|
|
350
|
+
/**
|
|
351
|
+
* Enable inlay hints
|
|
352
|
+
*/
|
|
353
|
+
inlayHints?: boolean;
|
|
354
|
+
/**
|
|
355
|
+
* Enable file rename edits
|
|
356
|
+
*/
|
|
357
|
+
fileRename?: boolean;
|
|
358
|
+
/**
|
|
359
|
+
* Enable Corsa-backed IDE features
|
|
360
|
+
*/
|
|
361
|
+
corsa?: boolean;
|
|
362
|
+
/**
|
|
363
|
+
* Deprecated alias for corsa
|
|
364
|
+
*/
|
|
365
|
+
tsgo?: boolean;
|
|
366
|
+
}
|
|
367
|
+
/**
|
|
368
|
+
* Musea component gallery options
|
|
369
|
+
*/
|
|
370
|
+
export interface MuseaConfig {
|
|
371
|
+
/**
|
|
372
|
+
* Glob patterns for art files
|
|
373
|
+
*/
|
|
374
|
+
include?: string[];
|
|
375
|
+
/**
|
|
376
|
+
* Glob patterns to exclude
|
|
377
|
+
*/
|
|
378
|
+
exclude?: string[];
|
|
379
|
+
/**
|
|
380
|
+
* Base path for gallery
|
|
381
|
+
*/
|
|
382
|
+
basePath?: string;
|
|
383
|
+
/**
|
|
384
|
+
* Enable Storybook compatibility
|
|
385
|
+
*/
|
|
386
|
+
storybookCompat?: boolean;
|
|
387
|
+
/**
|
|
388
|
+
* Enable inline art detection in .vue files
|
|
389
|
+
*/
|
|
390
|
+
inlineArt?: boolean;
|
|
391
|
+
vrt?: MuseaVrtConfig;
|
|
392
|
+
a11y?: MuseaA11yConfig;
|
|
393
|
+
autogen?: MuseaAutogenConfig;
|
|
394
|
+
}
|
|
395
|
+
/**
|
|
396
|
+
* VRT (Visual Regression Testing) configuration
|
|
397
|
+
*/
|
|
398
|
+
export interface MuseaVrtConfig {
|
|
399
|
+
/**
|
|
400
|
+
* Threshold for pixel comparison (0-1)
|
|
401
|
+
*/
|
|
402
|
+
threshold?: number;
|
|
403
|
+
/**
|
|
404
|
+
* Output directory for screenshots
|
|
405
|
+
*/
|
|
406
|
+
outDir?: string;
|
|
407
|
+
/**
|
|
408
|
+
* Viewport sizes
|
|
409
|
+
*/
|
|
410
|
+
viewports?: MuseaViewport[];
|
|
411
|
+
}
|
|
412
|
+
export interface MuseaViewport {
|
|
413
|
+
/**
|
|
414
|
+
* Viewport width
|
|
415
|
+
*/
|
|
416
|
+
width: number;
|
|
417
|
+
/**
|
|
418
|
+
* Viewport height
|
|
419
|
+
*/
|
|
420
|
+
height: number;
|
|
421
|
+
/**
|
|
422
|
+
* Viewport name
|
|
423
|
+
*/
|
|
424
|
+
name?: string;
|
|
425
|
+
}
|
|
426
|
+
/**
|
|
427
|
+
* A11y configuration
|
|
428
|
+
*/
|
|
429
|
+
export interface MuseaA11yConfig {
|
|
430
|
+
/**
|
|
431
|
+
* Enable a11y checking
|
|
432
|
+
*/
|
|
433
|
+
enabled?: boolean;
|
|
434
|
+
/**
|
|
435
|
+
* Axe-core rules to enable/disable
|
|
436
|
+
*/
|
|
437
|
+
rules?: {
|
|
438
|
+
[k: string]: boolean;
|
|
439
|
+
};
|
|
440
|
+
}
|
|
441
|
+
/**
|
|
442
|
+
* Autogen configuration
|
|
443
|
+
*/
|
|
444
|
+
export interface MuseaAutogenConfig {
|
|
445
|
+
/**
|
|
446
|
+
* Enable auto-generation of variants
|
|
447
|
+
*/
|
|
448
|
+
enabled?: boolean;
|
|
449
|
+
/**
|
|
450
|
+
* Max variants to generate per component
|
|
451
|
+
*/
|
|
452
|
+
maxVariants?: number;
|
|
453
|
+
}
|
|
454
|
+
/**
|
|
455
|
+
* Global type declarations
|
|
456
|
+
*/
|
|
457
|
+
export interface GlobalTypesConfig {
|
|
458
|
+
[k: string]: string | GlobalTypeDeclaration;
|
|
459
|
+
}
|
|
460
|
+
/**
|
|
461
|
+
* Global type declaration
|
|
462
|
+
*/
|
|
463
|
+
export interface GlobalTypeDeclaration {
|
|
464
|
+
/**
|
|
465
|
+
* TypeScript type string
|
|
466
|
+
*/
|
|
467
|
+
type: string;
|
|
468
|
+
/**
|
|
469
|
+
* Default value
|
|
470
|
+
*/
|
|
471
|
+
defaultValue?: string;
|
|
472
|
+
}
|
package/src/types/index.ts
CHANGED
|
@@ -1,19 +1,28 @@
|
|
|
1
1
|
export type {
|
|
2
|
-
MaybePromise,
|
|
3
|
-
ConfigEnv,
|
|
4
|
-
UserConfigExport,
|
|
5
2
|
LintPreset,
|
|
6
3
|
RuleSeverity,
|
|
7
4
|
RuleCategory,
|
|
8
5
|
VizeConfig,
|
|
9
|
-
|
|
6
|
+
CompilerConfig,
|
|
7
|
+
VitePluginConfig,
|
|
8
|
+
LinterConfig,
|
|
9
|
+
TypeCheckerConfig,
|
|
10
|
+
FormatterConfig,
|
|
11
|
+
LanguageServerConfig,
|
|
12
|
+
MuseaVrtConfig,
|
|
13
|
+
MuseaA11yConfig,
|
|
14
|
+
MuseaAutogenConfig,
|
|
15
|
+
MuseaConfig,
|
|
16
|
+
MuseaViewport,
|
|
17
|
+
GlobalTypeDeclaration,
|
|
18
|
+
GlobalTypesConfig,
|
|
19
|
+
} from "./generated.js";
|
|
10
20
|
|
|
11
21
|
export type { LintRuleName, LintRulesConfig } from "./rules.js";
|
|
12
22
|
|
|
13
|
-
|
|
23
|
+
/**
|
|
24
|
+
* @deprecated Use `LanguageServerConfig`.
|
|
25
|
+
*/
|
|
26
|
+
export type LspConfig = import("./generated.js").LanguageServerConfig;
|
|
14
27
|
|
|
15
|
-
export type {
|
|
16
|
-
|
|
17
|
-
export type { MuseaVrtConfig, MuseaA11yConfig, MuseaAutogenConfig, MuseaConfig } from "./musea.js";
|
|
18
|
-
|
|
19
|
-
export type { GlobalTypeDeclaration, GlobalTypesConfig, LoadConfigOptions } from "./loader.js";
|
|
28
|
+
export type { MaybePromise, ConfigEnv, UserConfigExport, LoadConfigOptions } from "./runtime.js";
|
package/src/types/rules.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// This file is generated by `moon run --target native - -- < tools/moon/scripts/generate_rule_types.mbtx`.
|
|
2
2
|
// Do not edit it by hand.
|
|
3
3
|
|
|
4
|
-
import type { RuleSeverity } from "./
|
|
4
|
+
import type { RuleSeverity } from "./generated.js";
|
|
5
5
|
|
|
6
6
|
export const LINT_RULE_NAMES = [
|
|
7
7
|
"a11y/alt-text",
|
|
@@ -1,36 +1,31 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { LanguageServerConfig, VizeConfig } from "./generated.js";
|
|
2
2
|
|
|
3
3
|
// ============================================================================
|
|
4
|
-
//
|
|
4
|
+
// TS-specific runtime types (cannot be expressed in Pkl)
|
|
5
5
|
// ============================================================================
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
* Global type declaration
|
|
9
|
-
*/
|
|
10
|
-
export interface GlobalTypeDeclaration {
|
|
11
|
-
/**
|
|
12
|
-
* TypeScript type string
|
|
13
|
-
*/
|
|
14
|
-
type: string;
|
|
7
|
+
export type MaybePromise<T> = T | Promise<T>;
|
|
15
8
|
|
|
9
|
+
export interface ConfigEnv {
|
|
10
|
+
mode: string;
|
|
11
|
+
command: "serve" | "build" | "check" | "lint" | "fmt";
|
|
12
|
+
isSsrBuild?: boolean;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export type UserConfig = VizeConfig & {
|
|
16
16
|
/**
|
|
17
|
-
*
|
|
17
|
+
* Legacy alias for `languageServer`.
|
|
18
|
+
* Prefer `languageServer`.
|
|
18
19
|
*/
|
|
19
|
-
|
|
20
|
-
}
|
|
20
|
+
lsp?: LanguageServerConfig;
|
|
21
|
+
};
|
|
21
22
|
|
|
22
|
-
|
|
23
|
-
* Global types configuration
|
|
24
|
-
*/
|
|
25
|
-
export type GlobalTypesConfig = Record<string, GlobalTypeDeclaration | string>;
|
|
23
|
+
export type UserConfigExport = UserConfig | ((env: ConfigEnv) => MaybePromise<UserConfig>);
|
|
26
24
|
|
|
27
25
|
// ============================================================================
|
|
28
26
|
// LoadConfigOptions
|
|
29
27
|
// ============================================================================
|
|
30
28
|
|
|
31
|
-
/**
|
|
32
|
-
* Options for loading vize.config file
|
|
33
|
-
*/
|
|
34
29
|
export interface LoadConfigOptions {
|
|
35
30
|
/**
|
|
36
31
|
* Config file search mode
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"config-CTXni-Py.d.mts","names":[],"sources":["../src/types/compiler.ts","../src/types/rules.ts","../src/types/tools.ts","../src/types/musea.ts","../src/types/loader.ts","../src/types/core.ts","../src/config.ts"],"mappings":";;AAOA;;UAAiB,cAAA;EAAc;;;;EAK7B,IAAA;EAyBA;;;;EAnBA,KAAA;EAiDA;;;;;EA1CA,cAAA;EAgE+B;;;;EA1D/B,GAAA;EAqEsC;;;;EA/DtC,SAAA;EAyDsC;;;;EAnDtC,iBAAA;EAsEA;;;;EAhEA,WAAA;;;AC5CF;;EDkDE,aAAA;EC6DQ;;AAEV;;EDzDE,IAAA;ECyDiC;;AAEnC;;EDrDE,SAAA;ECqD2C;;;;ED/C3C,iBAAA;EC+CmC;;;;EDzCnC,iBAAA;AAAA;;;;UAUe,gBAAA;EE/EA;;;;EFoFf,OAAA,YAAmB,MAAA,aAAmB,MAAA;EEhEV;;;;EFsE5B,OAAA,YAAmB,MAAA,aAAmB,MAAA;EEtElB;;;;EF4EpB,YAAA;EEjFQ;;;;;EFwFR,mBAAA;EEnFsD;;AAUxD;;EF+EE,cAAA;AAAA;;;cClHW,eAAA;AAAA,KAiHD,YAAA,WAAuB,eAAA;AAAA,KAEvB,eAAA,GAAkB,OAAA,CAAQ,MAAA,CAAO,YAAA,EAAc,YAAA;;;;;;UC9G1C,YAAA;EFQf;;;EEJA,OAAA;EF6BA;;;;EEvBA,MAAA,GAAS,UAAA;EFqDT;;;EEhDA,KAAA,GAAQ,eAAA;EFgEO;;;EE3Df,UAAA,GAAa,OAAA,CAAQ,MAAA,CAAO,YAAA,EAAc,YAAA;AAAA;;;;UAU3B,iBAAA;EFsDf;;;;EEjDA,OAAA;EFuDsC;;;;EEjDtC,MAAA;EFoEc;;;;EE9Dd,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,oBAAA,CACd,MAAA,EAAQ,iBAAA,GACP,MAAA,SAAe,qBAAA"}
|
package/src/types/compiler.ts
DELETED
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
// ============================================================================
|
|
2
|
-
// CompilerConfig
|
|
3
|
-
// ============================================================================
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Compiler configuration
|
|
7
|
-
*/
|
|
8
|
-
export interface CompilerConfig {
|
|
9
|
-
/**
|
|
10
|
-
* Compilation mode
|
|
11
|
-
* @default 'module'
|
|
12
|
-
*/
|
|
13
|
-
mode?: "module" | "function";
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* Enable Vapor mode compilation
|
|
17
|
-
* @default false
|
|
18
|
-
*/
|
|
19
|
-
vapor?: boolean;
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Treat lowercase non-HTML tags as custom renderer elements instead of Vue components.
|
|
23
|
-
* Useful for TresJS and other custom renderers.
|
|
24
|
-
* @default false
|
|
25
|
-
*/
|
|
26
|
-
customRenderer?: boolean;
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* Enable SSR mode
|
|
30
|
-
* @default false
|
|
31
|
-
*/
|
|
32
|
-
ssr?: boolean;
|
|
33
|
-
|
|
34
|
-
/**
|
|
35
|
-
* Enable source map generation
|
|
36
|
-
* @default true in development, false in production
|
|
37
|
-
*/
|
|
38
|
-
sourceMap?: boolean;
|
|
39
|
-
|
|
40
|
-
/**
|
|
41
|
-
* Prefix template identifiers with _ctx
|
|
42
|
-
* @default false
|
|
43
|
-
*/
|
|
44
|
-
prefixIdentifiers?: boolean;
|
|
45
|
-
|
|
46
|
-
/**
|
|
47
|
-
* Hoist static nodes
|
|
48
|
-
* @default true
|
|
49
|
-
*/
|
|
50
|
-
hoistStatic?: boolean;
|
|
51
|
-
|
|
52
|
-
/**
|
|
53
|
-
* Cache v-on handlers
|
|
54
|
-
* @default true
|
|
55
|
-
*/
|
|
56
|
-
cacheHandlers?: boolean;
|
|
57
|
-
|
|
58
|
-
/**
|
|
59
|
-
* Enable TypeScript parsing in <script> blocks
|
|
60
|
-
* @default true
|
|
61
|
-
*/
|
|
62
|
-
isTs?: boolean;
|
|
63
|
-
|
|
64
|
-
/**
|
|
65
|
-
* Script file extension for generated output
|
|
66
|
-
* @default 'ts'
|
|
67
|
-
*/
|
|
68
|
-
scriptExt?: "ts" | "js";
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* Module name for runtime imports
|
|
72
|
-
* @default 'vue'
|
|
73
|
-
*/
|
|
74
|
-
runtimeModuleName?: string;
|
|
75
|
-
|
|
76
|
-
/**
|
|
77
|
-
* Global variable name for runtime (IIFE builds)
|
|
78
|
-
* @default 'Vue'
|
|
79
|
-
*/
|
|
80
|
-
runtimeGlobalName?: string;
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
// ============================================================================
|
|
84
|
-
// VitePluginConfig
|
|
85
|
-
// ============================================================================
|
|
86
|
-
|
|
87
|
-
/**
|
|
88
|
-
* Vite plugin configuration
|
|
89
|
-
*/
|
|
90
|
-
export interface VitePluginConfig {
|
|
91
|
-
/**
|
|
92
|
-
* Files to include in compilation
|
|
93
|
-
* @default /\.vue$/
|
|
94
|
-
*/
|
|
95
|
-
include?: string | RegExp | (string | RegExp)[];
|
|
96
|
-
|
|
97
|
-
/**
|
|
98
|
-
* Files to exclude from compilation
|
|
99
|
-
* @default /node_modules/
|
|
100
|
-
*/
|
|
101
|
-
exclude?: string | RegExp | (string | RegExp)[];
|
|
102
|
-
|
|
103
|
-
/**
|
|
104
|
-
* Glob patterns to scan for .vue files during pre-compilation
|
|
105
|
-
* @default ['**\/*.vue']
|
|
106
|
-
*/
|
|
107
|
-
scanPatterns?: string[];
|
|
108
|
-
|
|
109
|
-
/**
|
|
110
|
-
* Maximum number of Vue files to compile in a single native batch during
|
|
111
|
-
* pre-compilation. Lower values reduce peak V8 heap usage in large apps.
|
|
112
|
-
* @default 128
|
|
113
|
-
*/
|
|
114
|
-
precompileBatchSize?: number;
|
|
115
|
-
|
|
116
|
-
/**
|
|
117
|
-
* Glob patterns to ignore during pre-compilation
|
|
118
|
-
* @default ['node_modules/**', 'dist/**', '.git/**', '.nuxt/**', '.output/**', '.nitro/**', 'coverage/**']
|
|
119
|
-
*/
|
|
120
|
-
ignorePatterns?: string[];
|
|
121
|
-
}
|