@eslinted/defaults 12.10.0 → 12.11.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/.github/workflows/RELEASE.yml +36 -36
- package/.github/workflows/rc.yml +36 -36
- package/.markdownlint.jsonc +97 -97
- package/.mocharc.yml +15 -15
- package/LICENSE +20 -20
- package/README.md +4 -4
- package/dist/index.d.ts +99 -912
- package/dist/index.d.ts.map +1 -1
- package/dist/rules/index.d.ts +99 -492
- package/dist/rules/index.d.ts.map +1 -1
- package/dist/rules/scopes/enable.d.ts +0 -2
- package/dist/rules/scopes/enable.d.ts.map +1 -1
- package/dist/rules/scopes/enable.js +0 -3
- package/dist/rules/scopes/enable.js.map +1 -1
- package/dist/rules/scopes/enable.style.d.ts +24 -134
- package/dist/rules/scopes/enable.style.d.ts.map +1 -1
- package/dist/rules/scopes/enable.style.js +22 -192
- package/dist/rules/scopes/enable.style.js.map +1 -1
- package/dist/rules/scopes/index.d.ts +24 -136
- package/dist/rules/scopes/index.d.ts.map +1 -1
- package/dist/rules/scopes/json/index.d.ts +7 -20
- package/dist/rules/scopes/json/index.d.ts.map +1 -1
- package/dist/rules/scopes/json/plugin/extension.d.ts +7 -20
- package/dist/rules/scopes/json/plugin/extension.d.ts.map +1 -1
- package/dist/rules/scopes/json/plugin/extension.js +7 -41
- package/dist/rules/scopes/json/plugin/extension.js.map +1 -1
- package/dist/rules/scopes/mocha/chai/index.d.ts +0 -2
- package/dist/rules/scopes/mocha/chai/index.d.ts.map +1 -1
- package/dist/rules/scopes/mocha/chai/index.js +0 -2
- package/dist/rules/scopes/mocha/chai/index.js.map +1 -1
- package/dist/rules/scopes/mocha/enable.d.ts +3 -10
- package/dist/rules/scopes/mocha/enable.d.ts.map +1 -1
- package/dist/rules/scopes/mocha/enable.js +3 -19
- package/dist/rules/scopes/mocha/enable.js.map +1 -1
- package/dist/rules/scopes/mocha/index.d.ts +3 -12
- package/dist/rules/scopes/mocha/index.d.ts.map +1 -1
- package/dist/rules/scopes/svelte/enable.d.ts +19 -91
- package/dist/rules/scopes/svelte/enable.d.ts.map +1 -1
- package/dist/rules/scopes/svelte/enable.js +20 -153
- package/dist/rules/scopes/svelte/enable.js.map +1 -1
- package/dist/rules/scopes/svelte/extension/index.d.ts +2 -7
- package/dist/rules/scopes/svelte/extension/index.d.ts.map +1 -1
- package/dist/rules/scopes/svelte/extension/index.js +2 -11
- package/dist/rules/scopes/svelte/extension/index.js.map +1 -1
- package/dist/rules/scopes/svelte/index.d.ts +21 -98
- package/dist/rules/scopes/svelte/index.d.ts.map +1 -1
- package/dist/rules/scopes/ts/enable.d.ts +31 -163
- package/dist/rules/scopes/ts/enable.d.ts.map +1 -1
- package/dist/rules/scopes/ts/enable.js +32 -380
- package/dist/rules/scopes/ts/enable.js.map +1 -1
- package/dist/rules/scopes/ts/extension/index.d.ts +1 -20
- package/dist/rules/scopes/ts/extension/index.d.ts.map +1 -1
- package/dist/rules/scopes/ts/extension/index.js +2 -25
- package/dist/rules/scopes/ts/extension/index.js.map +1 -1
- package/dist/rules/scopes/ts/index.d.ts +32 -183
- package/dist/rules/scopes/ts/index.d.ts.map +1 -1
- package/dist/rules/scopes/yml/index.d.ts +12 -43
- package/dist/rules/scopes/yml/index.d.ts.map +1 -1
- package/dist/rules/scopes/yml/plugin/extension.d.ts +5 -22
- package/dist/rules/scopes/yml/plugin/extension.d.ts.map +1 -1
- package/dist/rules/scopes/yml/plugin/extension.js +5 -36
- package/dist/rules/scopes/yml/plugin/extension.js.map +1 -1
- package/dist/rules/scopes/yml/plugin/index.d.ts +7 -21
- package/dist/rules/scopes/yml/plugin/index.d.ts.map +1 -1
- package/dist/rules/scopes/yml/plugin/index.js +8 -44
- package/dist/rules/scopes/yml/plugin/index.js.map +1 -1
- package/eslint.config.js +3 -3
- package/package.json +56 -56
- package/src/files/_factory/index.ts +76 -76
- package/src/files/_factory/project/index.ts +2 -2
- package/src/files/_factory/project/roots.ts +4 -4
- package/src/files/_factory/project/subroots.ts +8 -8
- package/src/files/index.ts +23 -23
- package/src/files/scopes/css.ts +5 -5
- package/src/files/scopes/html.ts +5 -5
- package/src/files/scopes/js.ts +5 -5
- package/src/files/scopes/json.ts +5 -5
- package/src/files/scopes/jsonc.ts +5 -5
- package/src/files/scopes/jsoncc.ts +9 -9
- package/src/files/scopes/mocha.ts +5 -5
- package/src/files/scopes/svelte.ts +5 -5
- package/src/files/scopes/ts.ts +5 -5
- package/src/files/scopes/yml.ts +8 -8
- package/src/ignores/global.ts +5 -5
- package/src/ignores/index.ts +25 -25
- package/src/ignores/scopes/css.ts +1 -1
- package/src/ignores/scopes/html.ts +1 -1
- package/src/ignores/scopes/js.ts +1 -1
- package/src/ignores/scopes/json.ts +1 -1
- package/src/ignores/scopes/jsonc.ts +1 -1
- package/src/ignores/scopes/jsoncc.ts +1 -1
- package/src/ignores/scopes/mocha.ts +1 -1
- package/src/ignores/scopes/svelte.ts +1 -1
- package/src/ignores/scopes/ts.ts +1 -1
- package/src/ignores/scopes/yml.ts +1 -1
- package/src/index.ts +10 -10
- package/src/rules/_strings/id.ts +21 -21
- package/src/rules/_strings/index.ts +3 -3
- package/src/rules/_strings/option.ts +30 -30
- package/src/rules/_strings/state.spec.ts +64 -64
- package/src/rules/_strings/state.ts +4 -4
- package/src/rules/index.ts +23 -23
- package/src/rules/scopes/css/enable.ts +31 -31
- package/src/rules/scopes/css/index.ts +3 -3
- package/src/rules/scopes/enable.style.ts +507 -705
- package/src/rules/scopes/enable.ts +390 -401
- package/src/rules/scopes/html/index.ts +3 -3
- package/src/rules/scopes/html/plugin/index.ts +113 -113
- package/src/rules/scopes/index.ts +7 -7
- package/src/rules/scopes/json/enable.ts +18 -18
- package/src/rules/scopes/json/index.ts +9 -9
- package/src/rules/scopes/json/plugin/extension.ts +60 -98
- package/src/rules/scopes/json/plugin/index.ts +35 -35
- package/src/rules/scopes/jsonc/index.ts +3 -3
- package/src/rules/scopes/jsonc/plugin/index.ts +12 -12
- package/src/rules/scopes/jsoncc/index.ts +3 -3
- package/src/rules/scopes/jsoncc/plugin/index.ts +16 -16
- package/src/rules/scopes/mocha/chai/expect.ts +16 -16
- package/src/rules/scopes/mocha/chai/index.ts +18 -20
- package/src/rules/scopes/mocha/disable.ts +13 -13
- package/src/rules/scopes/mocha/enable.ts +36 -52
- package/src/rules/scopes/mocha/index.ts +11 -11
- package/src/rules/scopes/svelte/disable.ts +19 -19
- package/src/rules/scopes/svelte/enable.ts +157 -292
- package/src/rules/scopes/svelte/extension/disable.ts +14 -14
- package/src/rules/scopes/svelte/extension/index.ts +17 -27
- package/src/rules/scopes/svelte/index.ts +11 -11
- package/src/rules/scopes/ts/disable.ts +30 -30
- package/src/rules/scopes/ts/enable.ts +188 -578
- package/src/rules/scopes/ts/extension/disable.ts +35 -35
- package/src/rules/scopes/ts/extension/index.ts +62 -87
- package/src/rules/scopes/ts/index.ts +11 -11
- package/src/rules/scopes/yml/index.ts +7 -7
- package/src/rules/scopes/yml/plugin/extension.ts +55 -88
- package/src/rules/scopes/yml/plugin/index.ts +38 -88
- package/src/settings/global/index.ts +6 -6
- package/src/settings/index.ts +7 -7
- package/src/settings/registry/index.ts +23 -23
- package/src/settings/registry/manifests/css.ts +9 -9
- package/src/settings/registry/manifests/html.ts +10 -10
- package/src/settings/registry/manifests/js.ts +8 -8
- package/src/settings/registry/manifests/json.ts +7 -7
- package/src/settings/registry/manifests/jsonc.ts +9 -9
- package/src/settings/registry/manifests/jsoncc.ts +9 -9
- package/src/settings/registry/manifests/mocha.ts +8 -8
- package/src/settings/registry/manifests/svelte.ts +10 -10
- package/src/settings/registry/manifests/ts.ts +30 -30
- package/src/settings/registry/manifests/yml.ts +9 -9
- package/tsconfig.json +75 -156
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import {
|
|
2
|
-
ID,
|
|
3
|
-
OFF,
|
|
4
|
-
} from "../../../_strings";
|
|
5
|
-
|
|
6
|
-
export const TsDisableExtension = {
|
|
7
|
-
id: ID.Disable.Extension,
|
|
8
|
-
rules: {
|
|
9
|
-
// DOC: https://typescript-eslint.io/rules/?=extension-xdeprecated#rules
|
|
10
|
-
// "class-methods-use-this": OFF /* ESLint now supports TS */,
|
|
11
|
-
// "consistent-return": OFF /* tsc */,
|
|
12
|
-
// "default-param-last": OFF /* ESLint now supports TS */,
|
|
13
|
-
"dot-notation": OFF,
|
|
14
|
-
// "init-declarations": OFF /* ESLint now supports TS */,
|
|
15
|
-
// "max-params": OFF /* ESLint now supports TS */,
|
|
16
|
-
// "no-array-constructor": OFF /* ESLint now supports TS */,
|
|
17
|
-
// "no-dupe-class-members": OFF /* tsc, although ESLint now supports TS */,
|
|
18
|
-
// "no-empty-function": OFF /* ESLint now supports TS */,
|
|
19
|
-
"no-implied-eval": OFF,
|
|
20
|
-
// "no-invalid-this": OFF /* tsc, although ESLint now supports TS */,
|
|
21
|
-
// "no-loop-func": OFF /* ESLint now supports TS */,
|
|
22
|
-
// "no-magic-numbers": OFF /* ESLint now supports TS */,
|
|
23
|
-
// "no-redeclare": OFF /* tsc */,
|
|
24
|
-
"no-restricted-imports": OFF,
|
|
25
|
-
// "no-shadow": OFF /* ESLint now supports TS */,
|
|
26
|
-
"no-throw-literal": OFF /* @typescript-eslint/only-throw-error */,
|
|
27
|
-
// "no-unused-expressions": OFF /* ESLint now supports TS */,
|
|
28
|
-
"no-unused-vars": OFF,
|
|
29
|
-
// "no-use-before-define": OFF /* ESLint now supports TS */,
|
|
30
|
-
// "no-useless-constructor": OFF /* ESLint now supports TS */,
|
|
31
|
-
"prefer-destructuring": OFF,
|
|
32
|
-
"prefer-promise-reject-errors": OFF,
|
|
33
|
-
"require-await": OFF,
|
|
34
|
-
} as const,
|
|
35
|
-
};
|
|
1
|
+
import {
|
|
2
|
+
ID,
|
|
3
|
+
OFF,
|
|
4
|
+
} from "../../../_strings";
|
|
5
|
+
|
|
6
|
+
export const TsDisableExtension = {
|
|
7
|
+
id: ID.Disable.Extension,
|
|
8
|
+
rules: {
|
|
9
|
+
// DOC: https://typescript-eslint.io/rules/?=extension-xdeprecated#rules
|
|
10
|
+
// "class-methods-use-this": OFF /* ESLint now supports TS */,
|
|
11
|
+
// "consistent-return": OFF /* tsc */,
|
|
12
|
+
// "default-param-last": OFF /* ESLint now supports TS */,
|
|
13
|
+
"dot-notation": OFF,
|
|
14
|
+
// "init-declarations": OFF /* ESLint now supports TS */,
|
|
15
|
+
// "max-params": OFF /* ESLint now supports TS */,
|
|
16
|
+
// "no-array-constructor": OFF /* ESLint now supports TS */,
|
|
17
|
+
// "no-dupe-class-members": OFF /* tsc, although ESLint now supports TS */,
|
|
18
|
+
// "no-empty-function": OFF /* ESLint now supports TS */,
|
|
19
|
+
"no-implied-eval": OFF,
|
|
20
|
+
// "no-invalid-this": OFF /* tsc, although ESLint now supports TS */,
|
|
21
|
+
// "no-loop-func": OFF /* ESLint now supports TS */,
|
|
22
|
+
// "no-magic-numbers": OFF /* ESLint now supports TS */,
|
|
23
|
+
// "no-redeclare": OFF /* tsc */,
|
|
24
|
+
"no-restricted-imports": OFF,
|
|
25
|
+
// "no-shadow": OFF /* ESLint now supports TS */,
|
|
26
|
+
"no-throw-literal": OFF /* @typescript-eslint/only-throw-error */,
|
|
27
|
+
// "no-unused-expressions": OFF /* ESLint now supports TS */,
|
|
28
|
+
"no-unused-vars": OFF,
|
|
29
|
+
// "no-use-before-define": OFF /* ESLint now supports TS */,
|
|
30
|
+
// "no-useless-constructor": OFF /* ESLint now supports TS */,
|
|
31
|
+
"prefer-destructuring": OFF,
|
|
32
|
+
"prefer-promise-reject-errors": OFF,
|
|
33
|
+
"require-await": OFF,
|
|
34
|
+
} as const,
|
|
35
|
+
};
|
|
@@ -1,87 +1,62 @@
|
|
|
1
|
-
import {
|
|
2
|
-
ID,
|
|
3
|
-
// OFF,
|
|
4
|
-
ON,
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
//
|
|
12
|
-
// "@typescript-eslint/
|
|
13
|
-
// "@typescript-eslint/
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
// "@typescript-eslint/
|
|
27
|
-
// "@typescript-eslint/
|
|
28
|
-
|
|
29
|
-
// "@typescript-eslint/no-
|
|
30
|
-
// "@typescript-eslint/no-
|
|
31
|
-
"@typescript-eslint/no-
|
|
32
|
-
// "@typescript-eslint/no-
|
|
33
|
-
// "@typescript-eslint/no-
|
|
34
|
-
// "@typescript-eslint/no-
|
|
35
|
-
// "@typescript-eslint/no-
|
|
36
|
-
|
|
37
|
-
// "@typescript-eslint/no-
|
|
38
|
-
// "@typescript-eslint/no-
|
|
39
|
-
"@typescript-eslint/
|
|
40
|
-
ON,
|
|
41
|
-
{
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
allowThrowingUnknown:
|
|
58
|
-
},
|
|
59
|
-
],
|
|
60
|
-
"@typescript-eslint/
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
VariableDeclarator: {
|
|
64
|
-
array: true,
|
|
65
|
-
object: true,
|
|
66
|
-
},
|
|
67
|
-
AssignmentExpression: {
|
|
68
|
-
array: false,
|
|
69
|
-
object: false,
|
|
70
|
-
},
|
|
71
|
-
},
|
|
72
|
-
{
|
|
73
|
-
enforceForRenamedProperties: false,
|
|
74
|
-
enforceForDeclarationWithTypeAnnotation: false,
|
|
75
|
-
},
|
|
76
|
-
],
|
|
77
|
-
"@typescript-eslint/prefer-promise-reject-errors": [
|
|
78
|
-
ON,
|
|
79
|
-
{
|
|
80
|
-
allowEmptyReject: false,
|
|
81
|
-
allowThrowingAny: false,
|
|
82
|
-
allowThrowingUnknown: true,
|
|
83
|
-
},
|
|
84
|
-
],
|
|
85
|
-
"@typescript-eslint/require-await": ON,
|
|
86
|
-
} as const,
|
|
87
|
-
};
|
|
1
|
+
import {
|
|
2
|
+
ID,
|
|
3
|
+
// OFF,
|
|
4
|
+
ON,
|
|
5
|
+
} from "../../../_strings";
|
|
6
|
+
|
|
7
|
+
export const TsEnableExtension = {
|
|
8
|
+
id: ID.Enable.Extension,
|
|
9
|
+
rules: {
|
|
10
|
+
// DOC: https://typescript-eslint.io/rules/?=extension-xdeprecated#rules
|
|
11
|
+
// "@typescript-eslint/class-methods-use-this": OFF /* ESLint now supports TS (preference -- eslint:OFF) */,
|
|
12
|
+
// "@typescript-eslint/consistent-return": OFF /* tsc: noImplicitReturns */,
|
|
13
|
+
// "@typescript-eslint/default-param-last": OFF /* ESLint now supports TS */,
|
|
14
|
+
"@typescript-eslint/dot-notation": [
|
|
15
|
+
ON,
|
|
16
|
+
{
|
|
17
|
+
// TS-only:
|
|
18
|
+
allowPrivateClassPropertyAccess: true,
|
|
19
|
+
allowProtectedClassPropertyAccess: true,
|
|
20
|
+
allowIndexSignaturePropertyAccess: true,
|
|
21
|
+
},
|
|
22
|
+
],
|
|
23
|
+
// "@typescript-eslint/init-declarations": OFF /* ESLint now supports TS */,
|
|
24
|
+
// "@typescript-eslint/max-params": OFF /* preference, although ESLint now supports TS */,
|
|
25
|
+
// "@typescript-eslint/no-array-constructor": OFF /* ESLint now supports TS */,
|
|
26
|
+
// "@typescript-eslint/no-dupe-class-members": OFF /* tsc, although ESLint now supports TS */,
|
|
27
|
+
// "@typescript-eslint/no-empty-function": OFF /* ESLint now supports TS */,
|
|
28
|
+
"@typescript-eslint/no-implied-eval": ON,
|
|
29
|
+
// "@typescript-eslint/no-invalid-this": OFF /* tsc: { strict, noImplicitThis }, although ESLint now supports TS */,
|
|
30
|
+
// "@typescript-eslint/no-loop-func": OFF /* ESLint now supports TS */,
|
|
31
|
+
// "@typescript-eslint/no-magic-numbers": OFF /* preference, although ESLint now supports TS */,
|
|
32
|
+
// "@typescript-eslint/no-redeclare": OFF /* tsc (let, const, -var) */,
|
|
33
|
+
// "@typescript-eslint/no-restricted-imports": OFF /* preference */,
|
|
34
|
+
// "@typescript-eslint/no-shadow": OFF /* ESLint now supports TS (was: investigate) */,
|
|
35
|
+
// "@typescript-eslint/no-unused-expressions": OFF /* ESLint now supports TS (preference -- eslint:OFF) */,
|
|
36
|
+
"@typescript-eslint/no-unused-vars": ON,
|
|
37
|
+
// "@typescript-eslint/no-use-before-define": OFF /* ESLint now supports TS */,
|
|
38
|
+
// "@typescript-eslint/no-useless-constructor": OFF /* ESLint now supports TS */,
|
|
39
|
+
"@typescript-eslint/only-throw-error": [
|
|
40
|
+
ON,
|
|
41
|
+
{
|
|
42
|
+
allowThrowingAny: false,
|
|
43
|
+
},
|
|
44
|
+
],
|
|
45
|
+
"@typescript-eslint/prefer-destructuring": [
|
|
46
|
+
ON,
|
|
47
|
+
{
|
|
48
|
+
AssignmentExpression: {
|
|
49
|
+
array: false,
|
|
50
|
+
object: false,
|
|
51
|
+
},
|
|
52
|
+
},
|
|
53
|
+
],
|
|
54
|
+
"@typescript-eslint/prefer-promise-reject-errors": [
|
|
55
|
+
ON,
|
|
56
|
+
{
|
|
57
|
+
allowThrowingUnknown: true,
|
|
58
|
+
},
|
|
59
|
+
],
|
|
60
|
+
"@typescript-eslint/require-await": ON,
|
|
61
|
+
} as const,
|
|
62
|
+
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { TsDisable } from "./disable";
|
|
2
|
-
import { TsDisableExtension } from "./extension/disable";
|
|
3
|
-
import { TsEnable } from "./enable";
|
|
4
|
-
import { TsEnableExtension } from "./extension";
|
|
5
|
-
|
|
6
|
-
export default [
|
|
7
|
-
TsDisable,
|
|
8
|
-
TsDisableExtension,
|
|
9
|
-
TsEnable,
|
|
10
|
-
TsEnableExtension,
|
|
11
|
-
];
|
|
1
|
+
import { TsDisable } from "./disable";
|
|
2
|
+
import { TsDisableExtension } from "./extension/disable";
|
|
3
|
+
import { TsEnable } from "./enable";
|
|
4
|
+
import { TsEnableExtension } from "./extension";
|
|
5
|
+
|
|
6
|
+
export default [
|
|
7
|
+
TsDisable,
|
|
8
|
+
TsDisableExtension,
|
|
9
|
+
TsEnable,
|
|
10
|
+
TsEnableExtension,
|
|
11
|
+
];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { YmlEnablePlugin } from "./plugin";
|
|
2
|
-
import { YmlEnablePluginExtension } from "./plugin/extension";
|
|
3
|
-
|
|
4
|
-
export default [
|
|
5
|
-
YmlEnablePlugin,
|
|
6
|
-
YmlEnablePluginExtension,
|
|
7
|
-
];
|
|
1
|
+
import { YmlEnablePlugin } from "./plugin";
|
|
2
|
+
import { YmlEnablePluginExtension } from "./plugin/extension";
|
|
3
|
+
|
|
4
|
+
export default [
|
|
5
|
+
YmlEnablePlugin,
|
|
6
|
+
YmlEnablePluginExtension,
|
|
7
|
+
];
|
|
@@ -1,88 +1,55 @@
|
|
|
1
|
-
import {
|
|
2
|
-
ID,
|
|
3
|
-
ON,
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
skipQuotedScalars: true,
|
|
57
|
-
skipComments: false,
|
|
58
|
-
},
|
|
59
|
-
],
|
|
60
|
-
"yml/no-multiple-empty-lines": [
|
|
61
|
-
ON,
|
|
62
|
-
{
|
|
63
|
-
max: 1,
|
|
64
|
-
maxBOF: 0,
|
|
65
|
-
maxEOF: 0 /* INFO: auto-fix still keeps final line-break (eol character) at EOF even though unlike `stylistic`, `yml` does not have `eol-last` */,
|
|
66
|
-
},
|
|
67
|
-
] /* MUST match @stylistic/no-multiple-empty-lines */,
|
|
68
|
-
"yml/spaced-comment": [
|
|
69
|
-
ON,
|
|
70
|
-
always,
|
|
71
|
-
{
|
|
72
|
-
exceptions: ["#"],
|
|
73
|
-
markers: [
|
|
74
|
-
"!",
|
|
75
|
-
"@",
|
|
76
|
-
"#",
|
|
77
|
-
"##",
|
|
78
|
-
"###",
|
|
79
|
-
"####",
|
|
80
|
-
"#####",
|
|
81
|
-
"######",
|
|
82
|
-
"region",
|
|
83
|
-
"endregion",
|
|
84
|
-
],
|
|
85
|
-
},
|
|
86
|
-
] /* @OVERRIDE @stylistic/spaced-comment */,
|
|
87
|
-
} as const,
|
|
88
|
-
};
|
|
1
|
+
import {
|
|
2
|
+
ID,
|
|
3
|
+
ON,
|
|
4
|
+
always,
|
|
5
|
+
} from "../../../_strings";
|
|
6
|
+
|
|
7
|
+
export const YmlEnablePluginExtension = {
|
|
8
|
+
id: ID.Enable.Plugin.Extension,
|
|
9
|
+
rules: {
|
|
10
|
+
// DOC: https://ota-meshi.github.io/eslint-plugin-yml/rules/#extension-rules
|
|
11
|
+
"yml/flow-mapping-curly-newline": [
|
|
12
|
+
ON,
|
|
13
|
+
{
|
|
14
|
+
consistent: true,
|
|
15
|
+
multiline: true,
|
|
16
|
+
minProperties: 2,
|
|
17
|
+
},
|
|
18
|
+
] /* MUST match jsonc/object-curly-newline */,
|
|
19
|
+
"yml/flow-mapping-curly-spacing": [
|
|
20
|
+
ON,
|
|
21
|
+
always,
|
|
22
|
+
] /* MUST match jsonc/object-curly-spacing */,
|
|
23
|
+
"yml/flow-sequence-bracket-newline": ON /* @OVERRIDE jsonc/array-bracket-newline, instead -> MUST match its parent: @stylistic/array-bracket-newline */,
|
|
24
|
+
"yml/flow-sequence-bracket-spacing": ON /* MUST match jsonc/array-bracket-spacing */,
|
|
25
|
+
"yml/key-spacing": ON /* MUST match jsonc/key-spacing */,
|
|
26
|
+
"yml/no-irregular-whitespace": ON,
|
|
27
|
+
"yml/no-multiple-empty-lines": [
|
|
28
|
+
ON,
|
|
29
|
+
{
|
|
30
|
+
max: 1,
|
|
31
|
+
maxBOF: 0,
|
|
32
|
+
maxEOF: 0 /* INFO: auto-fix still keeps final line-break (eol character) at EOF even though unlike `stylistic`, `yml` does not have `eol-last` */,
|
|
33
|
+
},
|
|
34
|
+
] /* MUST match @stylistic/no-multiple-empty-lines */,
|
|
35
|
+
"yml/spaced-comment": [
|
|
36
|
+
ON,
|
|
37
|
+
always,
|
|
38
|
+
{
|
|
39
|
+
exceptions: ["#"],
|
|
40
|
+
markers: [
|
|
41
|
+
"!",
|
|
42
|
+
"@",
|
|
43
|
+
"#",
|
|
44
|
+
"##",
|
|
45
|
+
"###",
|
|
46
|
+
"####",
|
|
47
|
+
"#####",
|
|
48
|
+
"######",
|
|
49
|
+
"region",
|
|
50
|
+
"endregion",
|
|
51
|
+
],
|
|
52
|
+
},
|
|
53
|
+
] /* @OVERRIDE @stylistic/spaced-comment */,
|
|
54
|
+
} as const,
|
|
55
|
+
};
|
|
@@ -1,88 +1,38 @@
|
|
|
1
|
-
import {
|
|
2
|
-
ID,
|
|
3
|
-
// OFF,
|
|
4
|
-
ON,
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
"yml/block-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
"yml/
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
ON,
|
|
40
|
-
{
|
|
41
|
-
singleline: ignore /* always | never | @default ignore */,
|
|
42
|
-
multiline: always /* @default always | never | ignore */,
|
|
43
|
-
},
|
|
44
|
-
],
|
|
45
|
-
// "yml/file-extension": OFF,
|
|
46
|
-
"yml/indent": [
|
|
47
|
-
ON,
|
|
48
|
-
2,
|
|
49
|
-
{
|
|
50
|
-
alignMultilineFlowScalars: true /* @default: false */,
|
|
51
|
-
indentBlockSequences: true,
|
|
52
|
-
indicatorValueIndent: 2 /* @default: number option */,
|
|
53
|
-
},
|
|
54
|
-
],
|
|
55
|
-
// "yml/key-name-casing": OFF,
|
|
56
|
-
// "yml/no-empty-document": OFF,
|
|
57
|
-
"yml/no-empty-key": ON,
|
|
58
|
-
// "yml/no-empty-mapping-value": OFF /* PREFERENCE: breaks Home Assistant integration enablement shorthand style (would require a `{}` after) */,
|
|
59
|
-
"yml/no-empty-sequence-entry": ON,
|
|
60
|
-
"yml/no-tab-indent": ON,
|
|
61
|
-
"yml/no-trailing-zeros": ON,
|
|
62
|
-
"yml/plain-scalar": [
|
|
63
|
-
ON,
|
|
64
|
-
always,
|
|
65
|
-
/*
|
|
66
|
-
{
|
|
67
|
-
ignorePatterns: [
|
|
68
|
-
"[\\v\\f\\u0085\\u00a0\\u1680\\u180e\\u2000-\\u200b\\u2028\\u2029\\u202f\\u205f\\u3000\\ufeff]" // @default
|
|
69
|
-
],
|
|
70
|
-
overrides: {
|
|
71
|
-
[key]: null | "always" | "never",
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
*/
|
|
75
|
-
],
|
|
76
|
-
"yml/quotes": [
|
|
77
|
-
ON,
|
|
78
|
-
{
|
|
79
|
-
prefer: double,
|
|
80
|
-
avoidEscape: true,
|
|
81
|
-
},
|
|
82
|
-
],
|
|
83
|
-
"yml/require-string-key": ON,
|
|
84
|
-
// "yml/sort-keys": OFF,
|
|
85
|
-
// "yml/sort-sequence-values": OFF,
|
|
86
|
-
"yml/vue-custom-block/no-parsing-error": ON,
|
|
87
|
-
} as const,
|
|
88
|
-
};
|
|
1
|
+
import {
|
|
2
|
+
ID,
|
|
3
|
+
// OFF,
|
|
4
|
+
ON,
|
|
5
|
+
} from "../../../_strings";
|
|
6
|
+
|
|
7
|
+
export const YmlEnablePlugin = {
|
|
8
|
+
id: ID.Enable.Plugin.Plugin,
|
|
9
|
+
rules: {
|
|
10
|
+
// DOC: https://ota-meshi.github.io/eslint-plugin-yml/rules/#yaml-rules
|
|
11
|
+
"yml/block-mapping-colon-indicator-newline": ON,
|
|
12
|
+
"yml/block-mapping-question-indicator-newline": ON,
|
|
13
|
+
"yml/block-mapping": ON,
|
|
14
|
+
"yml/block-sequence-hyphen-indicator-newline": ON,
|
|
15
|
+
"yml/block-sequence": ON,
|
|
16
|
+
// "yml/file-extension": OFF,
|
|
17
|
+
"yml/indent": [
|
|
18
|
+
ON,
|
|
19
|
+
2,
|
|
20
|
+
{
|
|
21
|
+
alignMultilineFlowScalars: true,
|
|
22
|
+
},
|
|
23
|
+
],
|
|
24
|
+
// "yml/key-name-casing": OFF,
|
|
25
|
+
// "yml/no-empty-document": OFF,
|
|
26
|
+
"yml/no-empty-key": ON,
|
|
27
|
+
// "yml/no-empty-mapping-value": OFF /* PREFERENCE: breaks Home Assistant integration enablement shorthand style (would require a `{}` after) */,
|
|
28
|
+
"yml/no-empty-sequence-entry": ON,
|
|
29
|
+
"yml/no-tab-indent": ON,
|
|
30
|
+
"yml/no-trailing-zeros": ON,
|
|
31
|
+
"yml/plain-scalar": ON,
|
|
32
|
+
"yml/quotes": ON,
|
|
33
|
+
"yml/require-string-key": ON,
|
|
34
|
+
// "yml/sort-keys": OFF,
|
|
35
|
+
// "yml/sort-sequence-values": OFF,
|
|
36
|
+
"yml/vue-custom-block/no-parsing-error": ON,
|
|
37
|
+
} as const,
|
|
38
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export const global = {
|
|
2
|
-
ecmaVersion: 2023 as const,
|
|
3
|
-
sourceType: "module" as const,
|
|
4
|
-
noInlineConfig: false,
|
|
5
|
-
reportUnusedDisableDirectives: "error" as const,
|
|
6
|
-
};
|
|
1
|
+
export const global = {
|
|
2
|
+
ecmaVersion: 2023 as const,
|
|
3
|
+
sourceType: "module" as const,
|
|
4
|
+
noInlineConfig: false,
|
|
5
|
+
reportUnusedDisableDirectives: "error" as const,
|
|
6
|
+
};
|
package/src/settings/index.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { global } from "./global";
|
|
2
|
-
import { registry } from "./registry";
|
|
3
|
-
|
|
4
|
-
export const settings = {
|
|
5
|
-
global,
|
|
6
|
-
registry,
|
|
7
|
-
};
|
|
1
|
+
import { global } from "./global";
|
|
2
|
+
import { registry } from "./registry";
|
|
3
|
+
|
|
4
|
+
export const settings = {
|
|
5
|
+
global,
|
|
6
|
+
registry,
|
|
7
|
+
};
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { js } from "./manifests/js";
|
|
2
|
-
import { ts } from "./manifests/ts";
|
|
3
|
-
import { mocha } from "./manifests/mocha";
|
|
4
|
-
import { svelte } from "./manifests/svelte";
|
|
5
|
-
import { html } from "./manifests/html";
|
|
6
|
-
import { css } from "./manifests/css";
|
|
7
|
-
import { json } from "./manifests/json";
|
|
8
|
-
import { jsonc } from "./manifests/jsonc";
|
|
9
|
-
import { jsoncc } from "./manifests/jsoncc";
|
|
10
|
-
import { yml } from "./manifests/yml";
|
|
11
|
-
|
|
12
|
-
export const registry = {
|
|
13
|
-
js,
|
|
14
|
-
ts,
|
|
15
|
-
mocha,
|
|
16
|
-
svelte,
|
|
17
|
-
html,
|
|
18
|
-
css,
|
|
19
|
-
json,
|
|
20
|
-
jsonc,
|
|
21
|
-
jsoncc,
|
|
22
|
-
yml,
|
|
23
|
-
};
|
|
1
|
+
import { js } from "./manifests/js";
|
|
2
|
+
import { ts } from "./manifests/ts";
|
|
3
|
+
import { mocha } from "./manifests/mocha";
|
|
4
|
+
import { svelte } from "./manifests/svelte";
|
|
5
|
+
import { html } from "./manifests/html";
|
|
6
|
+
import { css } from "./manifests/css";
|
|
7
|
+
import { json } from "./manifests/json";
|
|
8
|
+
import { jsonc } from "./manifests/jsonc";
|
|
9
|
+
import { jsoncc } from "./manifests/jsoncc";
|
|
10
|
+
import { yml } from "./manifests/yml";
|
|
11
|
+
|
|
12
|
+
export const registry = {
|
|
13
|
+
js,
|
|
14
|
+
ts,
|
|
15
|
+
mocha,
|
|
16
|
+
svelte,
|
|
17
|
+
html,
|
|
18
|
+
css,
|
|
19
|
+
json,
|
|
20
|
+
jsonc,
|
|
21
|
+
jsoncc,
|
|
22
|
+
yml,
|
|
23
|
+
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export const css = {
|
|
2
|
-
languageOptions: {
|
|
3
|
-
// DOC: https://github.com/eslint/css?tab=readme-ov-file#languages
|
|
4
|
-
tolerant: false /* @default: true | DOC: https://github.com/eslint/css?tab=readme-ov-file#tolerant-mode */,
|
|
5
|
-
// customSyntax: {} /* DOC: Tailwind: https://github.com/eslint/css?tab=readme-ov-file#configuring-tailwind-syntax | DOC: https://github.com/eslint/css?tab=readme-ov-file#configuring-custom-syntax */,
|
|
6
|
-
},
|
|
7
|
-
parserOptions: {},
|
|
8
|
-
language: "css/css",
|
|
9
|
-
};
|
|
1
|
+
export const css = {
|
|
2
|
+
languageOptions: {
|
|
3
|
+
// DOC: https://github.com/eslint/css?tab=readme-ov-file#languages
|
|
4
|
+
tolerant: false /* @default: true | DOC: https://github.com/eslint/css?tab=readme-ov-file#tolerant-mode */,
|
|
5
|
+
// customSyntax: {} /* DOC: Tailwind: https://github.com/eslint/css?tab=readme-ov-file#configuring-tailwind-syntax | DOC: https://github.com/eslint/css?tab=readme-ov-file#configuring-custom-syntax */,
|
|
6
|
+
},
|
|
7
|
+
parserOptions: {},
|
|
8
|
+
language: "css/css",
|
|
9
|
+
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export const html = {
|
|
2
|
-
languageOptions: {
|
|
3
|
-
parser: "html" as const,
|
|
4
|
-
},
|
|
5
|
-
parserOptions: {
|
|
6
|
-
// templateEngineSyntax: {} /* DOC: https://html-eslint.org/docs/integrating-template-engine */,
|
|
7
|
-
frontmatter: true /* @default: false | DOC: https://html-eslint.org/docs/integrating-template-engine#skip-frontmatter */,
|
|
8
|
-
},
|
|
9
|
-
language: "@html-eslint/html",
|
|
10
|
-
};
|
|
1
|
+
export const html = {
|
|
2
|
+
languageOptions: {
|
|
3
|
+
parser: "html" as const,
|
|
4
|
+
},
|
|
5
|
+
parserOptions: {
|
|
6
|
+
// templateEngineSyntax: {} /* DOC: https://html-eslint.org/docs/integrating-template-engine */,
|
|
7
|
+
frontmatter: true /* @default: false | DOC: https://html-eslint.org/docs/integrating-template-engine#skip-frontmatter */,
|
|
8
|
+
},
|
|
9
|
+
language: "@html-eslint/html",
|
|
10
|
+
};
|