@viberails/config 0.3.3 → 0.5.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/index.cjs +572 -330
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +317 -182
- package/dist/index.d.ts +317 -182
- package/dist/index.js +568 -330
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.d.cts
CHANGED
|
@@ -1,4 +1,17 @@
|
|
|
1
|
-
import { ConfigRules, ScanResult
|
|
1
|
+
import { ViberailsConfig, ConfigRules, ScanResult } from '@viberails/types';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Extract shared values from packages into defaults and strip them from packages.
|
|
5
|
+
* Only extracts values that are identical across ALL packages.
|
|
6
|
+
* Strips empty objects from packages for clean JSON output.
|
|
7
|
+
*/
|
|
8
|
+
declare function compactConfig(config: ViberailsConfig): ViberailsConfig;
|
|
9
|
+
/**
|
|
10
|
+
* Expand defaults into each package, producing fully self-contained packages.
|
|
11
|
+
* Inverse of compactConfig. Ensures every package has stack, structure,
|
|
12
|
+
* and conventions (even as empty objects) and config.ignore defaults to [].
|
|
13
|
+
*/
|
|
14
|
+
declare function expandDefaults(config: ViberailsConfig): ViberailsConfig;
|
|
2
15
|
|
|
3
16
|
/**
|
|
4
17
|
* Default rule thresholds and toggles for a new viberails config.
|
|
@@ -6,31 +19,49 @@ import { ConfigRules, ScanResult, ViberailsConfig } from '@viberails/types';
|
|
|
6
19
|
*/
|
|
7
20
|
declare const DEFAULT_RULES: ConfigRules;
|
|
8
21
|
/**
|
|
9
|
-
* Default
|
|
22
|
+
* Default project-specific ignore patterns for a new config.
|
|
23
|
+
* Empty — universal patterns live in BUILTIN_IGNORE and are applied at check-time.
|
|
10
24
|
*/
|
|
11
25
|
declare const DEFAULT_IGNORE: string[];
|
|
26
|
+
/**
|
|
27
|
+
* Universal ignore patterns applied at check-time.
|
|
28
|
+
* These are never written to config — they are always applied implicitly.
|
|
29
|
+
*/
|
|
30
|
+
declare const BUILTIN_IGNORE: string[];
|
|
12
31
|
|
|
13
32
|
/**
|
|
14
33
|
* Generate a ViberailsConfig from scan results.
|
|
15
34
|
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
35
|
+
* Produces the packages-first config format: all config lives in `packages[]`.
|
|
36
|
+
* Single projects get one package with `path: "."`.
|
|
37
|
+
* Monorepos get one package per workspace package.
|
|
19
38
|
*
|
|
20
39
|
* @param scanResult - The output of scanning a project
|
|
21
40
|
* @returns A complete ViberailsConfig ready to be written as JSON
|
|
22
41
|
*/
|
|
23
42
|
declare function generateConfig(scanResult: ScanResult): ViberailsConfig;
|
|
24
43
|
|
|
44
|
+
/**
|
|
45
|
+
* Infer a coverage command from the detected test runner string.
|
|
46
|
+
*
|
|
47
|
+
* Used during `init` to store the inferred command in config so that
|
|
48
|
+
* `check` can use it explicitly. Does not verify binary availability —
|
|
49
|
+
* the command is stored as a suggestion for the user to review.
|
|
50
|
+
*
|
|
51
|
+
* @param testRunner - Test runner string from config (e.g. "vitest@4", "jest@29")
|
|
52
|
+
* @returns Shell command string, or undefined if the runner is unsupported
|
|
53
|
+
*/
|
|
54
|
+
declare function inferCoverageCommand(testRunner: string | undefined): string | undefined;
|
|
55
|
+
|
|
25
56
|
/**
|
|
26
57
|
* Load and parse a viberails config file.
|
|
27
58
|
*
|
|
28
59
|
* Reads the JSON file at the given path, validates that it contains
|
|
29
|
-
* the required fields (version, name,
|
|
30
|
-
* the parsed config.
|
|
60
|
+
* the required fields (version, name, packages, rules), expands
|
|
61
|
+
* defaults into packages, and returns the parsed config.
|
|
31
62
|
*
|
|
32
63
|
* @param configPath - Absolute or relative path to viberails.config.json
|
|
33
|
-
* @returns The parsed ViberailsConfig
|
|
64
|
+
* @returns The parsed ViberailsConfig with defaults expanded
|
|
34
65
|
* @throws If the file doesn't exist, contains invalid JSON, or is missing required fields
|
|
35
66
|
*/
|
|
36
67
|
declare function loadConfig(configPath: string): Promise<ViberailsConfig>;
|
|
@@ -49,9 +80,8 @@ declare function loadConfigSafe(configPath: string): Promise<ViberailsConfig | n
|
|
|
49
80
|
* Merge a new scan result into an existing config for `viberails sync`.
|
|
50
81
|
*
|
|
51
82
|
* Preserves all developer-confirmed values from the existing config.
|
|
52
|
-
* Adds newly detected
|
|
53
|
-
* so the developer can review them.
|
|
54
|
-
* the developer has set.
|
|
83
|
+
* Adds newly detected values. New conventions are marked with
|
|
84
|
+
* `detected: true` in _meta so the developer can review them.
|
|
55
85
|
*
|
|
56
86
|
* @param existing - The current ViberailsConfig (from viberails.config.json)
|
|
57
87
|
* @param scanResult - Fresh scan results from re-scanning the project
|
|
@@ -65,7 +95,7 @@ declare const configSchema: {
|
|
|
65
95
|
readonly title: "viberails configuration";
|
|
66
96
|
readonly description: "Configuration file for viberails — guardrails for vibe coding.";
|
|
67
97
|
readonly type: "object";
|
|
68
|
-
readonly required: readonly ["version", "name", "
|
|
98
|
+
readonly required: readonly ["version", "name", "packages", "rules"];
|
|
69
99
|
readonly properties: {
|
|
70
100
|
readonly $schema: {
|
|
71
101
|
readonly type: "string";
|
|
@@ -74,123 +104,15 @@ declare const configSchema: {
|
|
|
74
104
|
readonly version: {
|
|
75
105
|
readonly type: "number";
|
|
76
106
|
readonly const: 1;
|
|
77
|
-
readonly description: "Config format version. Always 1
|
|
107
|
+
readonly description: "Config format version. Always 1.";
|
|
78
108
|
};
|
|
79
109
|
readonly name: {
|
|
80
110
|
readonly type: "string";
|
|
81
111
|
readonly description: "Project name, typically from package.json.";
|
|
82
112
|
};
|
|
83
|
-
readonly enforcement: {
|
|
84
|
-
readonly type: "string";
|
|
85
|
-
readonly enum: readonly ["warn", "enforce"];
|
|
86
|
-
readonly default: "warn";
|
|
87
|
-
readonly description: "Whether conventions are warned about or enforced as errors.";
|
|
88
|
-
};
|
|
89
|
-
readonly stack: {
|
|
90
|
-
readonly type: "object";
|
|
91
|
-
readonly required: readonly ["language", "packageManager"];
|
|
92
|
-
readonly properties: {
|
|
93
|
-
readonly framework: {
|
|
94
|
-
readonly type: "string";
|
|
95
|
-
readonly description: "Primary framework identifier (e.g. \"nextjs@15\", \"remix@2\").";
|
|
96
|
-
};
|
|
97
|
-
readonly language: {
|
|
98
|
-
readonly type: "string";
|
|
99
|
-
readonly description: "Primary language (e.g. \"typescript\", \"javascript\").";
|
|
100
|
-
};
|
|
101
|
-
readonly styling: {
|
|
102
|
-
readonly type: "string";
|
|
103
|
-
readonly description: "Styling solution (e.g. \"tailwindcss@4\", \"css-modules\").";
|
|
104
|
-
};
|
|
105
|
-
readonly backend: {
|
|
106
|
-
readonly type: "string";
|
|
107
|
-
readonly description: "Backend framework (e.g. \"express@5\", \"fastify\").";
|
|
108
|
-
};
|
|
109
|
-
readonly orm: {
|
|
110
|
-
readonly type: "string";
|
|
111
|
-
readonly description: "ORM or database client (e.g. \"prisma\", \"drizzle\", \"typeorm\").";
|
|
112
|
-
};
|
|
113
|
-
readonly packageManager: {
|
|
114
|
-
readonly type: "string";
|
|
115
|
-
readonly description: "Package manager (e.g. \"pnpm\", \"npm\", \"yarn\").";
|
|
116
|
-
};
|
|
117
|
-
readonly linter: {
|
|
118
|
-
readonly type: "string";
|
|
119
|
-
readonly description: "Linter (e.g. \"eslint@9\", \"biome\").";
|
|
120
|
-
};
|
|
121
|
-
readonly formatter: {
|
|
122
|
-
readonly type: "string";
|
|
123
|
-
readonly description: "Formatter (e.g. \"prettier\", \"biome\").";
|
|
124
|
-
};
|
|
125
|
-
readonly testRunner: {
|
|
126
|
-
readonly type: "string";
|
|
127
|
-
readonly description: "Test runner (e.g. \"vitest\", \"jest\").";
|
|
128
|
-
};
|
|
129
|
-
};
|
|
130
|
-
readonly additionalProperties: false;
|
|
131
|
-
readonly description: "Detected or configured technology stack.";
|
|
132
|
-
};
|
|
133
|
-
readonly structure: {
|
|
134
|
-
readonly type: "object";
|
|
135
|
-
readonly properties: {
|
|
136
|
-
readonly srcDir: {
|
|
137
|
-
readonly type: "string";
|
|
138
|
-
readonly description: "Source directory (e.g. \"src\"), or omit for flat structure.";
|
|
139
|
-
};
|
|
140
|
-
readonly pages: {
|
|
141
|
-
readonly type: "string";
|
|
142
|
-
readonly description: "Pages or routes directory (e.g. \"src/app\").";
|
|
143
|
-
};
|
|
144
|
-
readonly components: {
|
|
145
|
-
readonly type: "string";
|
|
146
|
-
readonly description: "Components directory (e.g. \"src/components\").";
|
|
147
|
-
};
|
|
148
|
-
readonly hooks: {
|
|
149
|
-
readonly type: "string";
|
|
150
|
-
readonly description: "Hooks directory (e.g. \"src/hooks\").";
|
|
151
|
-
};
|
|
152
|
-
readonly utils: {
|
|
153
|
-
readonly type: "string";
|
|
154
|
-
readonly description: "Utilities directory (e.g. \"src/utils\", \"src/lib\").";
|
|
155
|
-
};
|
|
156
|
-
readonly types: {
|
|
157
|
-
readonly type: "string";
|
|
158
|
-
readonly description: "Type definitions directory (e.g. \"src/types\").";
|
|
159
|
-
};
|
|
160
|
-
readonly tests: {
|
|
161
|
-
readonly type: "string";
|
|
162
|
-
readonly description: "Tests directory (e.g. \"tests\", \"__tests__\").";
|
|
163
|
-
};
|
|
164
|
-
readonly testPattern: {
|
|
165
|
-
readonly type: "string";
|
|
166
|
-
readonly description: "Test file naming pattern (e.g. \"*.test.ts\", \"*.spec.ts\").";
|
|
167
|
-
};
|
|
168
|
-
};
|
|
169
|
-
readonly additionalProperties: false;
|
|
170
|
-
readonly description: "Detected or configured directory structure.";
|
|
171
|
-
};
|
|
172
|
-
readonly conventions: {
|
|
173
|
-
readonly type: "object";
|
|
174
|
-
readonly properties: {
|
|
175
|
-
readonly fileNaming: {
|
|
176
|
-
readonly $ref: "#/definitions/conventionValue";
|
|
177
|
-
};
|
|
178
|
-
readonly componentNaming: {
|
|
179
|
-
readonly $ref: "#/definitions/conventionValue";
|
|
180
|
-
};
|
|
181
|
-
readonly hookNaming: {
|
|
182
|
-
readonly $ref: "#/definitions/conventionValue";
|
|
183
|
-
};
|
|
184
|
-
readonly importAlias: {
|
|
185
|
-
readonly $ref: "#/definitions/conventionValue";
|
|
186
|
-
};
|
|
187
|
-
};
|
|
188
|
-
readonly additionalProperties: false;
|
|
189
|
-
readonly description: "Detected or configured coding conventions.";
|
|
190
|
-
};
|
|
191
113
|
readonly rules: {
|
|
192
114
|
readonly type: "object";
|
|
193
|
-
readonly required: readonly ["maxFileLines", "
|
|
115
|
+
readonly required: readonly ["maxFileLines", "testCoverage", "enforceNaming", "enforceBoundaries", "enforceMissingTests"];
|
|
194
116
|
readonly properties: {
|
|
195
117
|
readonly maxFileLines: {
|
|
196
118
|
readonly type: "number";
|
|
@@ -200,17 +122,12 @@ declare const configSchema: {
|
|
|
200
122
|
readonly maxTestFileLines: {
|
|
201
123
|
readonly type: "number";
|
|
202
124
|
readonly default: 0;
|
|
203
|
-
readonly description: "Maximum number of lines allowed per test file. Set to 0 to exempt test files
|
|
125
|
+
readonly description: "Maximum number of lines allowed per test file. Set to 0 to exempt test files.";
|
|
204
126
|
};
|
|
205
|
-
readonly
|
|
127
|
+
readonly testCoverage: {
|
|
206
128
|
readonly type: "number";
|
|
207
|
-
readonly default:
|
|
208
|
-
readonly description: "
|
|
209
|
-
};
|
|
210
|
-
readonly requireTests: {
|
|
211
|
-
readonly type: "boolean";
|
|
212
|
-
readonly default: true;
|
|
213
|
-
readonly description: "Whether to require test files for source modules.";
|
|
129
|
+
readonly default: 80;
|
|
130
|
+
readonly description: "Minimum line coverage target percentage. 0 disables coverage threshold checks.";
|
|
214
131
|
};
|
|
215
132
|
readonly enforceNaming: {
|
|
216
133
|
readonly type: "boolean";
|
|
@@ -222,6 +139,11 @@ declare const configSchema: {
|
|
|
222
139
|
readonly default: false;
|
|
223
140
|
readonly description: "Whether to enforce module boundary rules.";
|
|
224
141
|
};
|
|
142
|
+
readonly enforceMissingTests: {
|
|
143
|
+
readonly type: "boolean";
|
|
144
|
+
readonly default: true;
|
|
145
|
+
readonly description: "Whether to enforce that every source file has a corresponding test file.";
|
|
146
|
+
};
|
|
225
147
|
};
|
|
226
148
|
readonly additionalProperties: false;
|
|
227
149
|
readonly description: "Rule thresholds and toggles for enforcement.";
|
|
@@ -231,7 +153,7 @@ declare const configSchema: {
|
|
|
231
153
|
readonly items: {
|
|
232
154
|
readonly type: "string";
|
|
233
155
|
};
|
|
234
|
-
readonly description: "
|
|
156
|
+
readonly description: "Project-specific glob patterns to ignore (universal patterns are built-in).";
|
|
235
157
|
};
|
|
236
158
|
readonly boundaries: {
|
|
237
159
|
readonly description: "Module boundary rules for import enforcement.";
|
|
@@ -258,24 +180,132 @@ declare const configSchema: {
|
|
|
258
180
|
};
|
|
259
181
|
readonly additionalProperties: false;
|
|
260
182
|
};
|
|
261
|
-
readonly
|
|
183
|
+
readonly defaults: {
|
|
262
184
|
readonly type: "object";
|
|
263
|
-
readonly required: readonly ["packages", "isMonorepo"];
|
|
264
185
|
readonly properties: {
|
|
265
|
-
readonly
|
|
266
|
-
readonly
|
|
267
|
-
readonly
|
|
268
|
-
|
|
186
|
+
readonly stack: {
|
|
187
|
+
readonly description: "Default stack inherited by all packages.";
|
|
188
|
+
readonly type: "object";
|
|
189
|
+
readonly properties: {
|
|
190
|
+
readonly framework: {
|
|
191
|
+
readonly type: "string";
|
|
192
|
+
readonly description: "Primary framework (e.g. \"nextjs@15\").";
|
|
193
|
+
};
|
|
194
|
+
readonly language: {
|
|
195
|
+
readonly type: "string";
|
|
196
|
+
readonly description: "Primary language (e.g. \"typescript\").";
|
|
197
|
+
};
|
|
198
|
+
readonly styling: {
|
|
199
|
+
readonly type: "string";
|
|
200
|
+
readonly description: "Styling solution (e.g. \"tailwindcss@4\").";
|
|
201
|
+
};
|
|
202
|
+
readonly backend: {
|
|
203
|
+
readonly type: "string";
|
|
204
|
+
readonly description: "Backend framework (e.g. \"express@5\").";
|
|
205
|
+
};
|
|
206
|
+
readonly orm: {
|
|
207
|
+
readonly type: "string";
|
|
208
|
+
readonly description: "ORM or database client (e.g. \"prisma\").";
|
|
209
|
+
};
|
|
210
|
+
readonly packageManager: {
|
|
211
|
+
readonly type: "string";
|
|
212
|
+
readonly description: "Package manager (e.g. \"pnpm\").";
|
|
213
|
+
};
|
|
214
|
+
readonly linter: {
|
|
215
|
+
readonly type: "string";
|
|
216
|
+
readonly description: "Linter (e.g. \"eslint@9\").";
|
|
217
|
+
};
|
|
218
|
+
readonly formatter: {
|
|
219
|
+
readonly type: "string";
|
|
220
|
+
readonly description: "Formatter (e.g. \"prettier\").";
|
|
221
|
+
};
|
|
222
|
+
readonly testRunner: {
|
|
223
|
+
readonly type: "string";
|
|
224
|
+
readonly description: "Test runner (e.g. \"vitest\").";
|
|
225
|
+
};
|
|
269
226
|
};
|
|
270
|
-
readonly
|
|
227
|
+
readonly additionalProperties: false;
|
|
271
228
|
};
|
|
272
|
-
readonly
|
|
273
|
-
readonly
|
|
274
|
-
readonly
|
|
229
|
+
readonly structure: {
|
|
230
|
+
readonly description: "Default structure inherited by all packages.";
|
|
231
|
+
readonly type: "object";
|
|
232
|
+
readonly properties: {
|
|
233
|
+
readonly srcDir: {
|
|
234
|
+
readonly type: "string";
|
|
235
|
+
readonly description: "Source directory (e.g. \"src\").";
|
|
236
|
+
};
|
|
237
|
+
readonly pages: {
|
|
238
|
+
readonly type: "string";
|
|
239
|
+
readonly description: "Pages or routes directory.";
|
|
240
|
+
};
|
|
241
|
+
readonly components: {
|
|
242
|
+
readonly type: "string";
|
|
243
|
+
readonly description: "Components directory.";
|
|
244
|
+
};
|
|
245
|
+
readonly hooks: {
|
|
246
|
+
readonly type: "string";
|
|
247
|
+
readonly description: "Hooks directory.";
|
|
248
|
+
};
|
|
249
|
+
readonly utils: {
|
|
250
|
+
readonly type: "string";
|
|
251
|
+
readonly description: "Utilities directory.";
|
|
252
|
+
};
|
|
253
|
+
readonly types: {
|
|
254
|
+
readonly type: "string";
|
|
255
|
+
readonly description: "Type definitions directory.";
|
|
256
|
+
};
|
|
257
|
+
readonly tests: {
|
|
258
|
+
readonly type: "string";
|
|
259
|
+
readonly description: "Tests directory.";
|
|
260
|
+
};
|
|
261
|
+
readonly testPattern: {
|
|
262
|
+
readonly type: "string";
|
|
263
|
+
readonly description: "Test file naming pattern (e.g. \"*.test.ts\").";
|
|
264
|
+
};
|
|
265
|
+
};
|
|
266
|
+
readonly additionalProperties: false;
|
|
267
|
+
};
|
|
268
|
+
readonly conventions: {
|
|
269
|
+
readonly description: "Default conventions inherited by all packages.";
|
|
270
|
+
readonly type: "object";
|
|
271
|
+
readonly properties: {
|
|
272
|
+
readonly fileNaming: {
|
|
273
|
+
readonly type: "string";
|
|
274
|
+
readonly description: "File naming convention (e.g. \"kebab-case\").";
|
|
275
|
+
};
|
|
276
|
+
readonly componentNaming: {
|
|
277
|
+
readonly type: "string";
|
|
278
|
+
readonly description: "Component naming convention.";
|
|
279
|
+
};
|
|
280
|
+
readonly hookNaming: {
|
|
281
|
+
readonly type: "string";
|
|
282
|
+
readonly description: "Hook naming convention.";
|
|
283
|
+
};
|
|
284
|
+
readonly importAlias: {
|
|
285
|
+
readonly type: "string";
|
|
286
|
+
readonly description: "Import alias pattern (e.g. \"@/*\").";
|
|
287
|
+
};
|
|
288
|
+
};
|
|
289
|
+
readonly additionalProperties: false;
|
|
290
|
+
};
|
|
291
|
+
readonly coverage: {
|
|
292
|
+
readonly description: "Default coverage settings inherited by all packages.";
|
|
293
|
+
readonly type: "object";
|
|
294
|
+
readonly properties: {
|
|
295
|
+
readonly command: {
|
|
296
|
+
readonly type: "string";
|
|
297
|
+
readonly description: "Command to generate coverage summary data for this package.";
|
|
298
|
+
};
|
|
299
|
+
readonly summaryPath: {
|
|
300
|
+
readonly type: "string";
|
|
301
|
+
readonly description: "Path to coverage summary JSON relative to package root.";
|
|
302
|
+
};
|
|
303
|
+
};
|
|
304
|
+
readonly additionalProperties: false;
|
|
275
305
|
};
|
|
276
306
|
};
|
|
277
307
|
readonly additionalProperties: false;
|
|
278
|
-
readonly description: "
|
|
308
|
+
readonly description: "Shared defaults for all packages. Packages inherit and can override.";
|
|
279
309
|
};
|
|
280
310
|
readonly packages: {
|
|
281
311
|
readonly type: "array";
|
|
@@ -289,43 +319,127 @@ declare const configSchema: {
|
|
|
289
319
|
};
|
|
290
320
|
readonly path: {
|
|
291
321
|
readonly type: "string";
|
|
292
|
-
readonly description: "Relative path to the package.";
|
|
322
|
+
readonly description: "Relative path to the package (\".\" for root).";
|
|
293
323
|
};
|
|
294
324
|
readonly stack: {
|
|
325
|
+
readonly description: "Technology stack for this package.";
|
|
295
326
|
readonly type: "object";
|
|
296
327
|
readonly properties: {
|
|
297
328
|
readonly framework: {
|
|
298
329
|
readonly type: "string";
|
|
330
|
+
readonly description: "Primary framework (e.g. \"nextjs@15\").";
|
|
299
331
|
};
|
|
300
332
|
readonly language: {
|
|
301
333
|
readonly type: "string";
|
|
334
|
+
readonly description: "Primary language (e.g. \"typescript\").";
|
|
302
335
|
};
|
|
303
336
|
readonly styling: {
|
|
304
337
|
readonly type: "string";
|
|
338
|
+
readonly description: "Styling solution (e.g. \"tailwindcss@4\").";
|
|
305
339
|
};
|
|
306
340
|
readonly backend: {
|
|
307
341
|
readonly type: "string";
|
|
342
|
+
readonly description: "Backend framework (e.g. \"express@5\").";
|
|
308
343
|
};
|
|
309
344
|
readonly orm: {
|
|
310
345
|
readonly type: "string";
|
|
346
|
+
readonly description: "ORM or database client (e.g. \"prisma\").";
|
|
311
347
|
};
|
|
312
348
|
readonly packageManager: {
|
|
313
349
|
readonly type: "string";
|
|
350
|
+
readonly description: "Package manager (e.g. \"pnpm\").";
|
|
314
351
|
};
|
|
315
352
|
readonly linter: {
|
|
316
353
|
readonly type: "string";
|
|
354
|
+
readonly description: "Linter (e.g. \"eslint@9\").";
|
|
317
355
|
};
|
|
318
356
|
readonly formatter: {
|
|
319
357
|
readonly type: "string";
|
|
358
|
+
readonly description: "Formatter (e.g. \"prettier\").";
|
|
320
359
|
};
|
|
321
360
|
readonly testRunner: {
|
|
322
361
|
readonly type: "string";
|
|
362
|
+
readonly description: "Test runner (e.g. \"vitest\").";
|
|
363
|
+
};
|
|
364
|
+
};
|
|
365
|
+
readonly additionalProperties: false;
|
|
366
|
+
};
|
|
367
|
+
readonly structure: {
|
|
368
|
+
readonly description: "Directory structure for this package.";
|
|
369
|
+
readonly type: "object";
|
|
370
|
+
readonly properties: {
|
|
371
|
+
readonly srcDir: {
|
|
372
|
+
readonly type: "string";
|
|
373
|
+
readonly description: "Source directory (e.g. \"src\").";
|
|
374
|
+
};
|
|
375
|
+
readonly pages: {
|
|
376
|
+
readonly type: "string";
|
|
377
|
+
readonly description: "Pages or routes directory.";
|
|
378
|
+
};
|
|
379
|
+
readonly components: {
|
|
380
|
+
readonly type: "string";
|
|
381
|
+
readonly description: "Components directory.";
|
|
382
|
+
};
|
|
383
|
+
readonly hooks: {
|
|
384
|
+
readonly type: "string";
|
|
385
|
+
readonly description: "Hooks directory.";
|
|
386
|
+
};
|
|
387
|
+
readonly utils: {
|
|
388
|
+
readonly type: "string";
|
|
389
|
+
readonly description: "Utilities directory.";
|
|
390
|
+
};
|
|
391
|
+
readonly types: {
|
|
392
|
+
readonly type: "string";
|
|
393
|
+
readonly description: "Type definitions directory.";
|
|
394
|
+
};
|
|
395
|
+
readonly tests: {
|
|
396
|
+
readonly type: "string";
|
|
397
|
+
readonly description: "Tests directory.";
|
|
398
|
+
};
|
|
399
|
+
readonly testPattern: {
|
|
400
|
+
readonly type: "string";
|
|
401
|
+
readonly description: "Test file naming pattern (e.g. \"*.test.ts\").";
|
|
323
402
|
};
|
|
324
403
|
};
|
|
325
404
|
readonly additionalProperties: false;
|
|
326
405
|
};
|
|
327
406
|
readonly conventions: {
|
|
328
|
-
readonly
|
|
407
|
+
readonly description: "Coding conventions for this package.";
|
|
408
|
+
readonly type: "object";
|
|
409
|
+
readonly properties: {
|
|
410
|
+
readonly fileNaming: {
|
|
411
|
+
readonly type: "string";
|
|
412
|
+
readonly description: "File naming convention (e.g. \"kebab-case\").";
|
|
413
|
+
};
|
|
414
|
+
readonly componentNaming: {
|
|
415
|
+
readonly type: "string";
|
|
416
|
+
readonly description: "Component naming convention.";
|
|
417
|
+
};
|
|
418
|
+
readonly hookNaming: {
|
|
419
|
+
readonly type: "string";
|
|
420
|
+
readonly description: "Hook naming convention.";
|
|
421
|
+
};
|
|
422
|
+
readonly importAlias: {
|
|
423
|
+
readonly type: "string";
|
|
424
|
+
readonly description: "Import alias pattern (e.g. \"@/*\").";
|
|
425
|
+
};
|
|
426
|
+
};
|
|
427
|
+
readonly additionalProperties: false;
|
|
428
|
+
};
|
|
429
|
+
readonly coverage: {
|
|
430
|
+
readonly description: "Coverage generation and summary settings for this package.";
|
|
431
|
+
readonly type: "object";
|
|
432
|
+
readonly properties: {
|
|
433
|
+
readonly command: {
|
|
434
|
+
readonly type: "string";
|
|
435
|
+
readonly description: "Command to generate coverage summary data for this package.";
|
|
436
|
+
};
|
|
437
|
+
readonly summaryPath: {
|
|
438
|
+
readonly type: "string";
|
|
439
|
+
readonly description: "Path to coverage summary JSON relative to package root.";
|
|
440
|
+
};
|
|
441
|
+
};
|
|
442
|
+
readonly additionalProperties: false;
|
|
329
443
|
};
|
|
330
444
|
readonly rules: {
|
|
331
445
|
readonly type: "object";
|
|
@@ -336,12 +450,9 @@ declare const configSchema: {
|
|
|
336
450
|
readonly maxTestFileLines: {
|
|
337
451
|
readonly type: "number";
|
|
338
452
|
};
|
|
339
|
-
readonly
|
|
453
|
+
readonly testCoverage: {
|
|
340
454
|
readonly type: "number";
|
|
341
455
|
};
|
|
342
|
-
readonly requireTests: {
|
|
343
|
-
readonly type: "boolean";
|
|
344
|
-
};
|
|
345
456
|
readonly enforceNaming: {
|
|
346
457
|
readonly type: "boolean";
|
|
347
458
|
};
|
|
@@ -357,48 +468,72 @@ declare const configSchema: {
|
|
|
357
468
|
readonly type: "string";
|
|
358
469
|
};
|
|
359
470
|
};
|
|
471
|
+
readonly boundaries: {
|
|
472
|
+
readonly type: "object";
|
|
473
|
+
readonly properties: {
|
|
474
|
+
readonly deny: {
|
|
475
|
+
readonly type: "array";
|
|
476
|
+
readonly items: {
|
|
477
|
+
readonly type: "string";
|
|
478
|
+
};
|
|
479
|
+
};
|
|
480
|
+
readonly ignore: {
|
|
481
|
+
readonly type: "array";
|
|
482
|
+
readonly items: {
|
|
483
|
+
readonly type: "string";
|
|
484
|
+
};
|
|
485
|
+
};
|
|
486
|
+
};
|
|
487
|
+
readonly additionalProperties: false;
|
|
488
|
+
};
|
|
360
489
|
};
|
|
361
490
|
readonly additionalProperties: false;
|
|
362
491
|
};
|
|
363
|
-
readonly description: "Per-package
|
|
492
|
+
readonly description: "Per-package configs. Single projects use path \".\".";
|
|
364
493
|
};
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
494
|
+
readonly _meta: {
|
|
495
|
+
readonly type: "object";
|
|
496
|
+
readonly properties: {
|
|
497
|
+
readonly lastSync: {
|
|
498
|
+
readonly type: "string";
|
|
499
|
+
readonly description: "ISO timestamp of last sync.";
|
|
500
|
+
};
|
|
501
|
+
readonly packages: {
|
|
502
|
+
readonly type: "object";
|
|
503
|
+
readonly additionalProperties: {
|
|
504
|
+
readonly type: "object";
|
|
505
|
+
readonly properties: {
|
|
506
|
+
readonly conventions: {
|
|
507
|
+
readonly type: "object";
|
|
508
|
+
readonly additionalProperties: {
|
|
509
|
+
readonly type: "object";
|
|
510
|
+
readonly properties: {
|
|
511
|
+
readonly value: {
|
|
512
|
+
readonly type: "string";
|
|
513
|
+
};
|
|
514
|
+
readonly confidence: {
|
|
515
|
+
readonly type: "string";
|
|
516
|
+
readonly enum: readonly ["high", "medium", "low"];
|
|
517
|
+
};
|
|
518
|
+
readonly consistency: {
|
|
519
|
+
readonly type: "number";
|
|
520
|
+
};
|
|
521
|
+
readonly detected: {
|
|
522
|
+
readonly type: "boolean";
|
|
523
|
+
};
|
|
524
|
+
};
|
|
525
|
+
};
|
|
526
|
+
};
|
|
527
|
+
};
|
|
394
528
|
};
|
|
395
529
|
};
|
|
396
|
-
|
|
397
|
-
|
|
530
|
+
};
|
|
531
|
+
readonly description: "Scanner metadata. Regenerated on every sync — not user-editable.";
|
|
398
532
|
};
|
|
399
533
|
};
|
|
534
|
+
readonly additionalProperties: false;
|
|
400
535
|
};
|
|
401
536
|
|
|
402
537
|
declare const VERSION: string;
|
|
403
538
|
|
|
404
|
-
export { DEFAULT_IGNORE, DEFAULT_RULES, VERSION, configSchema, generateConfig, loadConfig, loadConfigSafe, mergeConfig };
|
|
539
|
+
export { BUILTIN_IGNORE, DEFAULT_IGNORE, DEFAULT_RULES, VERSION, compactConfig, configSchema, expandDefaults, generateConfig, inferCoverageCommand, loadConfig, loadConfigSafe, mergeConfig };
|