Skip to content

Commit 573e88e

Browse files
committed
fix preset generation
1 parent f97f0d2 commit 573e88e

File tree

3 files changed

+32
-48
lines changed

3 files changed

+32
-48
lines changed

config-presets/all.json

Lines changed: 19 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -6,24 +6,20 @@
66
"if-directive-balance": 2,
77
"max-css-selectors": [
88
1,
9-
[
10-
{
11-
"maxSelectors": 1
12-
}
13-
]
9+
{
10+
"maxSelectors": 1
11+
}
1412
],
1513
"no-duplicated-css-declaration-props": 2,
1614
"no-duplicated-hint-platforms": 2,
1715
"no-duplicated-hints": 2,
1816
"no-duplicated-modifiers": 2,
1917
"no-excluded-rules": [
2018
2,
21-
[
22-
{
23-
"excludedRuleTexts": [],
24-
"excludedRegExpPatterns": []
25-
}
26-
]
19+
{
20+
"excludedRuleTexts": [],
21+
"excludedRegExpPatterns": []
22+
}
2723
],
2824
"no-inconsistent-hint-platforms": 2,
2925
"no-invalid-css-declaration": 2,
@@ -32,33 +28,27 @@
3228
"no-invalid-modifiers": 2,
3329
"no-short-rules": [
3430
2,
35-
[
36-
{
37-
"minLength": 4
38-
}
39-
]
31+
{
32+
"minLength": 4
33+
}
4034
],
4135
"no-unknown-hint-platforms": 2,
4236
"no-unknown-hints": 2,
4337
"no-unknown-preprocessor-directives": 2,
4438
"no-unsupported-css-pseudo-class": [
4539
2,
46-
[
47-
{
48-
"fuzzyThreshold": 0.6
49-
}
50-
]
40+
{
41+
"fuzzyThreshold": 0.6
42+
}
5143
],
5244
"scriptlet-quotes": [
5345
2,
54-
[
55-
{
56-
"adg": "double",
57-
"ubo": "none",
58-
"abp": "none",
59-
"disallowCurlyQuotes": true
60-
}
61-
]
46+
{
47+
"adg": "double",
48+
"ubo": "none",
49+
"abp": "none",
50+
"disallowCurlyQuotes": true
51+
}
6252
]
6353
}
6454
}

config-presets/recommended.json

Lines changed: 12 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -15,33 +15,27 @@
1515
"no-invalid-modifiers": 2,
1616
"no-short-rules": [
1717
2,
18-
[
19-
{
20-
"minLength": 4
21-
}
22-
]
18+
{
19+
"minLength": 4
20+
}
2321
],
2422
"no-unknown-hint-platforms": 2,
2523
"no-unknown-hints": 2,
2624
"no-unknown-preprocessor-directives": 2,
2725
"no-unsupported-css-pseudo-class": [
2826
2,
29-
[
30-
{
31-
"fuzzyThreshold": 0.6
32-
}
33-
]
27+
{
28+
"fuzzyThreshold": 0.6
29+
}
3430
],
3531
"scriptlet-quotes": [
3632
2,
37-
[
38-
{
39-
"adg": "double",
40-
"ubo": "none",
41-
"abp": "none",
42-
"disallowCurlyQuotes": true
43-
}
44-
]
33+
{
34+
"adg": "double",
35+
"ubo": "none",
36+
"abp": "none",
37+
"disallowCurlyQuotes": true
38+
}
4539
]
4640
}
4741
}

tasks/generate-presets.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ async function main() {
4141
let ruleConfig: LinterRuleConfig;
4242

4343
if (rule.meta.configSchema && rule.meta.defaultConfig) {
44-
ruleConfig = [severity, rule.meta.defaultConfig];
44+
ruleConfig = [severity, ...rule.meta.defaultConfig];
4545
} else {
4646
ruleConfig = severity;
4747
}

0 commit comments

Comments
 (0)