@eslinted/defaults 17.10.0 → 18.0.0-rc.1
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.d.ts +246 -265
- package/dist/index.d.ts.map +1 -1
- package/dist/rules/css/index.d.ts +9 -9
- package/dist/rules/css/index.js +9 -9
- package/dist/rules/css/index.js.map +1 -1
- package/dist/rules/html/index.d.ts +42 -42
- package/dist/rules/html/index.d.ts.map +1 -1
- package/dist/rules/html/index.js +42 -42
- package/dist/rules/html/index.js.map +1 -1
- package/dist/rules/index.d.ts +246 -265
- package/dist/rules/index.d.ts.map +1 -1
- package/dist/rules/js.d.ts +112 -119
- package/dist/rules/js.d.ts.map +1 -1
- package/dist/rules/js.eslint.d.ts +45 -52
- package/dist/rules/js.eslint.d.ts.map +1 -1
- package/dist/rules/js.eslint.js +45 -52
- package/dist/rules/js.eslint.js.map +1 -1
- package/dist/rules/js.stylistic.d.ts +67 -67
- package/dist/rules/js.stylistic.d.ts.map +1 -1
- package/dist/rules/js.stylistic.js +67 -67
- package/dist/rules/js.stylistic.js.map +1 -1
- package/dist/rules/json/index.d.ts +8 -11
- package/dist/rules/json/index.d.ts.map +1 -1
- package/dist/rules/json/plugin/extend.d.ts +8 -11
- package/dist/rules/json/plugin/extend.d.ts.map +1 -1
- package/dist/rules/json/plugin/extend.js +8 -11
- package/dist/rules/json/plugin/extend.js.map +1 -1
- package/dist/rules/jsoncc/index.d.ts +1 -1
- package/dist/rules/jsoncc/index.js +1 -1
- package/dist/rules/svelte/extend.d.ts +1 -1
- package/dist/rules/svelte/extend.js +1 -1
- package/dist/rules/svelte/extend.js.map +1 -1
- package/dist/rules/svelte/index.d.ts +24 -24
- package/dist/rules/svelte/svelte.d.ts +23 -23
- package/dist/rules/svelte/svelte.js +23 -23
- package/dist/rules/svelte/svelte.js.map +1 -1
- package/dist/rules/ts/extend.d.ts +4 -13
- package/dist/rules/ts/extend.d.ts.map +1 -1
- package/dist/rules/ts/extend.js +4 -13
- package/dist/rules/ts/extend.js.map +1 -1
- package/dist/rules/ts/index.d.ts +31 -41
- package/dist/rules/ts/index.d.ts.map +1 -1
- package/dist/rules/ts/ts.d.ts +27 -28
- package/dist/rules/ts/ts.d.ts.map +1 -1
- package/dist/rules/ts/ts.js +27 -28
- package/dist/rules/ts/ts.js.map +1 -1
- package/dist/rules/yml/extend.d.ts +7 -7
- package/dist/rules/yml/extend.js +7 -7
- package/dist/rules/yml/extend.js.map +1 -1
- package/dist/rules/yml/index.d.ts +19 -18
- package/dist/rules/yml/index.d.ts.map +1 -1
- package/dist/rules/yml/yml.d.ts +12 -11
- package/dist/rules/yml/yml.d.ts.map +1 -1
- package/dist/rules/yml/yml.js +12 -11
- package/dist/rules/yml/yml.js.map +1 -1
- package/package.json +1 -1
- package/src/rules/css/index.ts +11 -11
- package/src/rules/html/index.ts +50 -58
- package/src/rules/js.eslint.ts +143 -162
- package/src/rules/js.stylistic.ts +87 -88
- package/src/rules/json/json.ts +3 -3
- package/src/rules/json/plugin/extend.ts +11 -14
- package/src/rules/json/plugin/index.ts +3 -3
- package/src/rules/jsonc/index.ts +1 -1
- package/src/rules/jsoncc/index.ts +2 -2
- package/src/rules/svelte/disable.ts +3 -3
- package/src/rules/svelte/extend.ts +3 -3
- package/src/rules/svelte/svelte.ts +26 -26
- package/src/rules/ts/disable.ts +4 -4
- package/src/rules/ts/extend.ts +7 -15
- package/src/rules/ts/ts.ts +44 -44
- package/src/rules/yml/extend.ts +7 -7
- package/src/rules/yml/yml.ts +15 -15
- package/tsconfig-base.json +2 -4
package/src/rules/ts/ts.ts
CHANGED
|
@@ -4,26 +4,26 @@ import { State } from "../state";
|
|
|
4
4
|
export default {
|
|
5
5
|
rules: {
|
|
6
6
|
// "ts/adjacent-overload-signatures": State.OFF,
|
|
7
|
-
// "ts/array-type": State.OFF /* preference: ideally, I'd like to don't-care mutable arrays while requiring readonly [] syntax for immutable arrays, but there is no way to do that with the current rule options */,
|
|
7
|
+
// "ts/array-type": State.OFF /* @preference: ideally, I'd like to don't-care mutable arrays while requiring readonly [] syntax for immutable arrays, but there is no way to do that with the current rule options */,
|
|
8
8
|
"ts/await-thenable": State.ON,
|
|
9
|
-
"ts/ban-ts-comment": State.
|
|
10
|
-
"ts/ban-tslint-comment": State.
|
|
11
|
-
"ts/class-literal-property-style": State.
|
|
12
|
-
"ts/consistent-generic-constructors": State.
|
|
13
|
-
// "ts/consistent-indexed-object-style": State.OFF
|
|
9
|
+
"ts/ban-ts-comment": State.WARN,
|
|
10
|
+
"ts/ban-tslint-comment": State.WARN,
|
|
11
|
+
"ts/class-literal-property-style": State.WARN,
|
|
12
|
+
"ts/consistent-generic-constructors": State.WARN,
|
|
13
|
+
// "ts/consistent-indexed-object-style": State.OFF,
|
|
14
14
|
"ts/consistent-type-assertions": [
|
|
15
|
-
State.
|
|
15
|
+
State.WARN,
|
|
16
16
|
{
|
|
17
17
|
arrayLiteralTypeAssertions: "never",
|
|
18
18
|
objectLiteralTypeAssertions: "never",
|
|
19
19
|
},
|
|
20
20
|
],
|
|
21
21
|
// "ts/consistent-type-definitions": State.OFF,
|
|
22
|
-
"ts/consistent-type-exports": State.
|
|
23
|
-
"ts/consistent-type-imports": State.
|
|
22
|
+
"ts/consistent-type-exports": State.WARN,
|
|
23
|
+
"ts/consistent-type-imports": State.WARN,
|
|
24
24
|
// "ts/explicit-function-return-type": State.OFF,
|
|
25
25
|
"ts/explicit-member-accessibility": [
|
|
26
|
-
State.
|
|
26
|
+
State.WARN,
|
|
27
27
|
{
|
|
28
28
|
overrides: {
|
|
29
29
|
constructors: "no-public",
|
|
@@ -32,14 +32,14 @@ export default {
|
|
|
32
32
|
],
|
|
33
33
|
// "ts/explicit-module-boundary-types": State.OFF,
|
|
34
34
|
"ts/member-ordering": [
|
|
35
|
-
State.
|
|
35
|
+
State.WARN,
|
|
36
36
|
{
|
|
37
37
|
"default": {
|
|
38
38
|
optionalityOrder: "required-first",
|
|
39
39
|
},
|
|
40
40
|
},
|
|
41
41
|
],
|
|
42
|
-
"ts/method-signature-style": State.
|
|
42
|
+
"ts/method-signature-style": State.WARN,
|
|
43
43
|
// "ts/naming-convention": State.OFF,
|
|
44
44
|
"ts/no-array-delete": State.ON,
|
|
45
45
|
"ts/no-base-to-string": State.ON,
|
|
@@ -72,7 +72,7 @@ export default {
|
|
|
72
72
|
"ts/no-for-in-array": State.ON,
|
|
73
73
|
"ts/no-import-type-side-effects": State.ON,
|
|
74
74
|
"ts/no-inferrable-types": State.ON,
|
|
75
|
-
// "ts/no-invalid-void-type": State.OFF /* preference
|
|
75
|
+
// "ts/no-invalid-void-type": State.OFF /* @preference: I powerfully ideologically disagree with disallowing void, a valid type */,
|
|
76
76
|
"ts/no-meaningless-void-operator": [
|
|
77
77
|
State.ON,
|
|
78
78
|
{
|
|
@@ -86,9 +86,9 @@ export default {
|
|
|
86
86
|
"ts/no-namespace": State.ON,
|
|
87
87
|
"ts/no-non-null-asserted-nullish-coalescing": State.ON,
|
|
88
88
|
"ts/no-non-null-asserted-optional-chain": State.ON,
|
|
89
|
-
// "ts/no-non-null-assertion": State.OFF
|
|
89
|
+
// "ts/no-non-null-assertion": State.OFF,
|
|
90
90
|
"ts/no-redundant-type-constituents": State.ON,
|
|
91
|
-
// "ts/no-restricted-types": State.OFF /* preference
|
|
91
|
+
// "ts/no-restricted-types": State.OFF /* @preference: no shared custom types across all projects that I wish to ban */,
|
|
92
92
|
"ts/no-require-imports": State.ON,
|
|
93
93
|
"ts/no-this-alias": State.ON,
|
|
94
94
|
"ts/no-unnecessary-boolean-literal-compare": State.ON,
|
|
@@ -105,7 +105,7 @@ export default {
|
|
|
105
105
|
"ts/no-unsafe-assignment": State.ON,
|
|
106
106
|
"ts/no-unsafe-call": State.ON,
|
|
107
107
|
"ts/no-unsafe-declaration-merging": State.ON,
|
|
108
|
-
// "ts/no-unsafe-enum-comparison": State.OFF
|
|
108
|
+
// "ts/no-unsafe-enum-comparison": State.OFF,
|
|
109
109
|
"ts/no-unsafe-function-type": State.ON,
|
|
110
110
|
"ts/no-unsafe-member-access": [
|
|
111
111
|
State.ON,
|
|
@@ -116,35 +116,35 @@ export default {
|
|
|
116
116
|
"ts/no-unsafe-return": State.ON,
|
|
117
117
|
// "ts/no-unsafe-type-assertion": State.OFF,
|
|
118
118
|
"ts/no-unsafe-unary-minus": State.ON,
|
|
119
|
-
"ts/no-unused-private-class-members": State.
|
|
120
|
-
// "ts/no-useless-default-assignment": State.OFF /* BUG:
|
|
121
|
-
"ts/no-useless-empty-export": State.
|
|
119
|
+
"ts/no-unused-private-class-members": State.WARN,
|
|
120
|
+
// "ts/no-useless-default-assignment": State.OFF /* BUG: it's broken */,
|
|
121
|
+
"ts/no-useless-empty-export": State.WARN,
|
|
122
122
|
"ts/no-wrapper-object-types": State.ON,
|
|
123
|
-
// "ts/non-nullable-type-assertion-style": State.OFF
|
|
123
|
+
// "ts/non-nullable-type-assertion-style": State.OFF,
|
|
124
124
|
"ts/parameter-properties": [
|
|
125
|
-
State.
|
|
125
|
+
State.WARN,
|
|
126
126
|
{
|
|
127
|
-
prefer: "parameter-property"
|
|
127
|
+
prefer: "parameter-property",
|
|
128
128
|
},
|
|
129
129
|
],
|
|
130
|
-
"ts/prefer-as-const": State.
|
|
131
|
-
// "ts/prefer-enum-initializers": State.OFF
|
|
132
|
-
"ts/prefer-find": State.
|
|
133
|
-
"ts/prefer-for-of": State.
|
|
134
|
-
"ts/prefer-function-type": State.
|
|
135
|
-
"ts/prefer-includes": State.
|
|
136
|
-
// "ts/prefer-literal-enum-member": State.OFF /* preference
|
|
137
|
-
"ts/prefer-namespace-keyword": State.
|
|
130
|
+
"ts/prefer-as-const": State.WARN,
|
|
131
|
+
// "ts/prefer-enum-initializers": State.OFF,
|
|
132
|
+
"ts/prefer-find": State.WARN,
|
|
133
|
+
"ts/prefer-for-of": State.WARN,
|
|
134
|
+
"ts/prefer-function-type": State.WARN,
|
|
135
|
+
"ts/prefer-includes": State.WARN,
|
|
136
|
+
// "ts/prefer-literal-enum-member": State.OFF /* @preference: idk why this would be considering, maybe we should ban all variable scopes */,
|
|
137
|
+
"ts/prefer-namespace-keyword": State.WARN,
|
|
138
138
|
"ts/prefer-nullish-coalescing": [
|
|
139
|
-
State.
|
|
139
|
+
State.WARN,
|
|
140
140
|
{
|
|
141
141
|
ignoreMixedLogicalExpressions: true,
|
|
142
142
|
ignorePrimitives: true,
|
|
143
143
|
|
|
144
144
|
},
|
|
145
|
-
] /* requires
|
|
145
|
+
] /* @requires @tsc: strictNullChecks */,
|
|
146
146
|
"ts/prefer-optional-chain": [
|
|
147
|
-
State.
|
|
147
|
+
State.WARN,
|
|
148
148
|
{
|
|
149
149
|
checkBigInt: false,
|
|
150
150
|
checkBoolean: false,
|
|
@@ -152,15 +152,15 @@ export default {
|
|
|
152
152
|
checkString: false,
|
|
153
153
|
},
|
|
154
154
|
],
|
|
155
|
-
"ts/prefer-readonly": State.
|
|
156
|
-
// "ts/prefer-readonly-parameter-types": State.OFF /* preference
|
|
157
|
-
"ts/prefer-reduce-type-parameter": State.
|
|
158
|
-
"ts/prefer-regexp-exec": State.
|
|
159
|
-
"ts/prefer-return-this-type": State.
|
|
160
|
-
"ts/prefer-string-starts-ends-with": State.
|
|
155
|
+
"ts/prefer-readonly": State.WARN,
|
|
156
|
+
// "ts/prefer-readonly-parameter-types": State.OFF /* @preference: WAY too restrictive */,
|
|
157
|
+
"ts/prefer-reduce-type-parameter": State.WARN,
|
|
158
|
+
"ts/prefer-regexp-exec": State.WARN,
|
|
159
|
+
"ts/prefer-return-this-type": State.WARN,
|
|
160
|
+
"ts/prefer-string-starts-ends-with": State.WARN,
|
|
161
161
|
"ts/promise-function-async": State.ON,
|
|
162
|
-
"ts/related-getter-setter-pairs": State.
|
|
163
|
-
"ts/require-array-sort-compare": State.
|
|
162
|
+
// "ts/related-getter-setter-pairs": State.OFF,
|
|
163
|
+
"ts/require-array-sort-compare": State.WARN,
|
|
164
164
|
"ts/restrict-plus-operands": [
|
|
165
165
|
State.ON,
|
|
166
166
|
{
|
|
@@ -187,7 +187,7 @@ export default {
|
|
|
187
187
|
allowNullableNumber: true,
|
|
188
188
|
allowNullableString: true,
|
|
189
189
|
},
|
|
190
|
-
], /* requires
|
|
190
|
+
], /* @requires @tsc: strictNullChecks */
|
|
191
191
|
"ts/switch-exhaustiveness-check": [
|
|
192
192
|
State.ON,
|
|
193
193
|
{
|
|
@@ -195,8 +195,8 @@ export default {
|
|
|
195
195
|
considerDefaultExhaustiveForUnions: true,
|
|
196
196
|
},
|
|
197
197
|
],
|
|
198
|
-
// "ts/triple-slash-reference": State.OFF
|
|
199
|
-
// "ts/typedef": State.OFF /*
|
|
198
|
+
// "ts/triple-slash-reference": State.OFF,
|
|
199
|
+
// "ts/typedef": State.OFF /* @tsc: noImplicitAny, strictPropertyInitialization */,
|
|
200
200
|
"ts/unbound-method": [
|
|
201
201
|
State.ON,
|
|
202
202
|
{
|
package/src/rules/yml/extend.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { State } from "../state";
|
|
|
4
4
|
export default {
|
|
5
5
|
rules: {
|
|
6
6
|
"yml/flow-mapping-curly-newline": [
|
|
7
|
-
State.
|
|
7
|
+
State.WARN,
|
|
8
8
|
{
|
|
9
9
|
consistent: true,
|
|
10
10
|
multiline: true,
|
|
@@ -12,18 +12,18 @@ export default {
|
|
|
12
12
|
},
|
|
13
13
|
] /* MUST match jsonc/object-curly-newline */,
|
|
14
14
|
"yml/flow-mapping-curly-spacing": [
|
|
15
|
-
State.
|
|
15
|
+
State.WARN,
|
|
16
16
|
"never",
|
|
17
17
|
{
|
|
18
18
|
objectsInObjects: true,
|
|
19
19
|
},
|
|
20
20
|
] /* @OVERRIDE jsonc/object-curly-spacing */,
|
|
21
|
-
"yml/flow-sequence-bracket-newline": State.
|
|
22
|
-
"yml/flow-sequence-bracket-spacing": State.
|
|
23
|
-
"yml/key-spacing": State.
|
|
21
|
+
"yml/flow-sequence-bracket-newline": State.WARN /* @OVERRIDE jsonc/array-bracket-newline, instead -> MUST match its parent: stylistic/array-bracket-newline */,
|
|
22
|
+
"yml/flow-sequence-bracket-spacing": State.WARN /* MUST match jsonc/array-bracket-spacing */,
|
|
23
|
+
"yml/key-spacing": State.WARN /* MUST match jsonc/key-spacing */,
|
|
24
24
|
"yml/no-irregular-whitespace": State.ON,
|
|
25
25
|
"yml/no-multiple-empty-lines": [
|
|
26
|
-
State.
|
|
26
|
+
State.WARN,
|
|
27
27
|
{
|
|
28
28
|
max: 1,
|
|
29
29
|
maxBOF: 0,
|
|
@@ -31,7 +31,7 @@ export default {
|
|
|
31
31
|
},
|
|
32
32
|
] /* MUST match stylistic/no-multiple-empty-lines */,
|
|
33
33
|
"yml/spaced-comment": [
|
|
34
|
-
State.
|
|
34
|
+
State.WARN,
|
|
35
35
|
"always",
|
|
36
36
|
{
|
|
37
37
|
exceptions: ["#"],
|
package/src/rules/yml/yml.ts
CHANGED
|
@@ -3,25 +3,25 @@ import { State } from "../state";
|
|
|
3
3
|
// DOC: https://ota-meshi.github.io/eslint-plugin-yml/rules/#yaml-rules
|
|
4
4
|
export default {
|
|
5
5
|
rules: {
|
|
6
|
-
"yml/block-mapping-colon-indicator-newline": State.
|
|
7
|
-
"yml/block-mapping-question-indicator-newline": State.
|
|
8
|
-
"yml/block-mapping": State.
|
|
9
|
-
"yml/block-sequence-hyphen-indicator-newline": State.
|
|
10
|
-
"yml/block-sequence": State.
|
|
6
|
+
"yml/block-mapping-colon-indicator-newline": State.WARN,
|
|
7
|
+
"yml/block-mapping-question-indicator-newline": State.WARN,
|
|
8
|
+
"yml/block-mapping": State.WARN,
|
|
9
|
+
"yml/block-sequence-hyphen-indicator-newline": State.WARN,
|
|
10
|
+
"yml/block-sequence": State.WARN,
|
|
11
11
|
// "yml/file-extension": State.OFF,
|
|
12
|
-
"yml/indent": State.
|
|
12
|
+
"yml/indent": State.WARN,
|
|
13
13
|
// "yml/key-name-casing": State.OFF,
|
|
14
14
|
// "yml/no-empty-document": State.OFF,
|
|
15
|
-
"yml/no-empty-key": State.
|
|
16
|
-
// "yml/no-empty-mapping-value": State.OFF /*
|
|
17
|
-
"yml/no-empty-sequence-entry": State.
|
|
18
|
-
"yml/no-tab-indent": State.
|
|
19
|
-
"yml/no-trailing-zeros": State.
|
|
20
|
-
// "yml/plain-scalar": State.OFF /* breaks any holdovers from YAML 1.1 or non-YAML 1.2 core implementers */,
|
|
21
|
-
|
|
22
|
-
"yml/require-string-key": State.
|
|
15
|
+
"yml/no-empty-key": State.WARN,
|
|
16
|
+
// "yml/no-empty-mapping-value": State.OFF /* @preference: breaks Home Assistant integration enablement shorthand style (would require a `{}` after) */,
|
|
17
|
+
"yml/no-empty-sequence-entry": State.WARN,
|
|
18
|
+
"yml/no-tab-indent": State.WARN,
|
|
19
|
+
"yml/no-trailing-zeros": State.WARN,
|
|
20
|
+
// "yml/plain-scalar": State.OFF /* @CONFLICT: breaks any holdovers from YAML 1.1 or non-YAML 1.2 core implementers */,
|
|
21
|
+
"yml/quotes": State.WARN,
|
|
22
|
+
"yml/require-string-key": State.WARN,
|
|
23
23
|
// "yml/sort-keys": State.OFF,
|
|
24
24
|
// "yml/sort-sequence-values": State.OFF,
|
|
25
|
-
// "yml/vue-custom-block/no-parsing-error": State.OFF
|
|
25
|
+
// "yml/vue-custom-block/no-parsing-error": State.OFF,
|
|
26
26
|
} as const,
|
|
27
27
|
};
|
package/tsconfig-base.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"display": "tsc@509.7.
|
|
2
|
+
"display": "tsc@509.7.1",
|
|
3
3
|
"$help": "https://aka.ms/tsconfig/#quick-nav-Top%20Level",
|
|
4
4
|
"compilerOptions": {
|
|
5
5
|
"allowUnreachableCode": false,
|
|
@@ -17,9 +17,7 @@
|
|
|
17
17
|
"module": "esnext",
|
|
18
18
|
"moduleResolution": "bundler",
|
|
19
19
|
"rewriteRelativeImportExtensions": true,
|
|
20
|
-
"types": [
|
|
21
|
-
/* {CONFIGURE} */
|
|
22
|
-
],
|
|
20
|
+
"types": [],
|
|
23
21
|
"declaration": true,
|
|
24
22
|
"declarationMap": true,
|
|
25
23
|
"noEmitOnError": true,
|