@uniflowed/config 0.0.0-alpha.7 → 0.0.0-alpha.9
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/index.js +1 -0
- package/internal/schema.js +47 -1
- package/package.json +1 -1
package/index.js
CHANGED
package/internal/schema.js
CHANGED
|
@@ -16,6 +16,19 @@ export type TaskDefinition =
|
|
|
16
16
|
|
|
17
17
|
export type CapabilityJsHost = "node" | "deno" | "bun";
|
|
18
18
|
|
|
19
|
+
/**
|
|
20
|
+
* Percentages a coverage gate requires, as whole numbers between 0 and 100.
|
|
21
|
+
*
|
|
22
|
+
* A metric nobody names is not checked, which is not the same as requiring
|
|
23
|
+
* zero: `{ lines: 0 }` says "every line, and I mean it" in a way that reads
|
|
24
|
+
* wrong, so the absent case is the one that means nothing is required.
|
|
25
|
+
*/
|
|
26
|
+
export type CoverageThresholds = {
|
|
27
|
+
readonly lines?: number,
|
|
28
|
+
readonly functions?: number,
|
|
29
|
+
readonly branches?: number,
|
|
30
|
+
};
|
|
31
|
+
|
|
19
32
|
export type UniflowedConfig = {
|
|
20
33
|
readonly app?: {
|
|
21
34
|
readonly orm?: {
|
|
@@ -56,6 +69,22 @@ export type UniflowedConfig = {
|
|
|
56
69
|
},
|
|
57
70
|
readonly cache?: "opt-in",
|
|
58
71
|
},
|
|
72
|
+
readonly images?: {
|
|
73
|
+
readonly enabled?: boolean,
|
|
74
|
+
// The widths a layout asks for. uf emits one variant per width that is
|
|
75
|
+
// not wider than the source, plus one at the source's own width.
|
|
76
|
+
readonly widths?: $ReadOnlyArray<number>,
|
|
77
|
+
readonly quality?: number,
|
|
78
|
+
readonly placeholder?: boolean,
|
|
79
|
+
},
|
|
80
|
+
readonly fonts?: {
|
|
81
|
+
readonly enabled?: boolean,
|
|
82
|
+
readonly display?: string,
|
|
83
|
+
// The local face uf scales into a metric-matched fallback. One of the
|
|
84
|
+
// faces `uf_assets::font::LOCAL_FACES` knows the metrics of, because
|
|
85
|
+
// the scaling is a ratio against real numbers rather than a guess.
|
|
86
|
+
readonly fallback?: string,
|
|
87
|
+
},
|
|
59
88
|
readonly motion?: {
|
|
60
89
|
readonly module?: "@uniflowed/motion",
|
|
61
90
|
readonly engine?: "uf-native",
|
|
@@ -156,7 +185,7 @@ export type UniflowedConfig = {
|
|
|
156
185
|
readonly printer?: "uf-rust",
|
|
157
186
|
},
|
|
158
187
|
readonly nonFlow?: {
|
|
159
|
-
readonly formatter?: "biome",
|
|
188
|
+
readonly formatter?: "biome" | "prettier" | "none",
|
|
160
189
|
},
|
|
161
190
|
readonly quotes?: "single" | "double",
|
|
162
191
|
readonly semicolons?: boolean,
|
|
@@ -290,6 +319,23 @@ export type UniflowedConfig = {
|
|
|
290
319
|
readonly officialFlowParser?: true,
|
|
291
320
|
},
|
|
292
321
|
readonly reactTestingLibraryNative?: true,
|
|
322
|
+
/**
|
|
323
|
+
* What `uf test --coverage` measures, writes and fails on.
|
|
324
|
+
*
|
|
325
|
+
* The thresholds live here rather than on the command line because a
|
|
326
|
+
* coverage gate is a property of the project: the number CI fails on has to
|
|
327
|
+
* be the number a laptop fails on. They are checked whenever coverage was
|
|
328
|
+
* collected, so `enabled: false` plus `--coverage` still gates.
|
|
329
|
+
*/
|
|
330
|
+
readonly coverage?: {
|
|
331
|
+
readonly enabled?: boolean,
|
|
332
|
+
readonly directory?: string,
|
|
333
|
+
readonly reporters?: $ReadOnlyArray<"text" | "lcov" | "cobertura">,
|
|
334
|
+
readonly include?: $ReadOnlyArray<string>,
|
|
335
|
+
readonly exclude?: $ReadOnlyArray<string>,
|
|
336
|
+
readonly thresholds?: CoverageThresholds,
|
|
337
|
+
readonly perFileThresholds?: CoverageThresholds,
|
|
338
|
+
},
|
|
293
339
|
},
|
|
294
340
|
readonly tasks?: { readonly [string]: TaskDefinition },
|
|
295
341
|
readonly vrt?: {
|