linted 16.12.2-rc.0 → 16.12.2-rc.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (189) hide show
  1. package/.github/workflows/RELEASE.yml +35 -35
  2. package/.github/workflows/rc.yml +35 -35
  3. package/LICENSE +21 -21
  4. package/README.md +390 -390
  5. package/SECURITY.md +9 -9
  6. package/dist/imports/plugins.d.ts.map +1 -1
  7. package/dist/imports.d.ts.map +1 -1
  8. package/dist/rules/html/enable.d.ts +8 -0
  9. package/dist/rules/html/enable.d.ts.map +1 -0
  10. package/dist/rules/html/enable.js +15 -0
  11. package/dist/rules/html/enable.js.map +1 -0
  12. package/dist/rules/html/enable_recommended.d.ts +3 -0
  13. package/dist/rules/html/enable_recommended.d.ts.map +1 -0
  14. package/dist/rules/html/enable_recommended.js +8 -0
  15. package/dist/rules/html/enable_recommended.js.map +1 -0
  16. package/dist/rules/html.d.ts +8 -0
  17. package/dist/rules/html.d.ts.map +1 -0
  18. package/dist/rules/html.js +4 -0
  19. package/dist/rules/html.js.map +1 -0
  20. package/dist/rules/js/enable.d.ts +348 -0
  21. package/dist/rules/js/enable.d.ts.map +1 -0
  22. package/dist/rules/js/enable.js +496 -0
  23. package/dist/rules/js/enable.js.map +1 -0
  24. package/dist/rules/js/enable_stylistic.d.ts +420 -0
  25. package/dist/rules/js/enable_stylistic.d.ts.map +1 -0
  26. package/dist/rules/js/enable_stylistic.js +585 -0
  27. package/dist/rules/js/enable_stylistic.js.map +1 -0
  28. package/dist/rules/js.d.ts +765 -0
  29. package/dist/rules/js.d.ts.map +1 -0
  30. package/dist/rules/js.js +4 -0
  31. package/dist/rules/js.js.map +1 -0
  32. package/dist/rules/json/enable.d.ts +27 -0
  33. package/dist/rules/json/enable.d.ts.map +1 -0
  34. package/dist/rules/json/enable.js +31 -0
  35. package/dist/rules/json/enable.js.map +1 -0
  36. package/dist/rules/json/enable_x.d.ts.map +1 -1
  37. package/dist/rules/json/enable_x.js +48 -8
  38. package/dist/rules/json/enable_x.js.map +1 -1
  39. package/dist/rules/json.d.ts +74 -0
  40. package/dist/rules/json.d.ts.map +1 -0
  41. package/dist/rules/json.js +4 -0
  42. package/dist/rules/json.js.map +1 -0
  43. package/dist/rules/jsonc/override.d.ts.map +1 -1
  44. package/dist/rules/jsonc/override.js +12 -3
  45. package/dist/rules/jsonc/override.js.map +1 -1
  46. package/dist/rules/jsonc.d.ts +77 -0
  47. package/dist/rules/jsonc.d.ts.map +1 -0
  48. package/dist/rules/jsonc.js +4 -0
  49. package/dist/rules/jsonc.js.map +1 -0
  50. package/dist/rules/md/enable.d.ts +7 -0
  51. package/dist/rules/md/enable.d.ts.map +1 -0
  52. package/dist/rules/md/enable.js +14 -0
  53. package/dist/rules/md/enable.js.map +1 -0
  54. package/dist/rules/md.d.ts +7 -0
  55. package/dist/rules/md.d.ts.map +1 -0
  56. package/dist/rules/md.js +3 -0
  57. package/dist/rules/md.js.map +1 -0
  58. package/dist/rules/mocha/enable.d.ts +3 -0
  59. package/dist/rules/mocha/enable.d.ts.map +1 -0
  60. package/dist/rules/mocha/enable.js +3 -0
  61. package/dist/rules/mocha/enable.js.map +1 -0
  62. package/dist/rules/mocha/enable_recommended.d.ts +3 -0
  63. package/dist/rules/mocha/enable_recommended.d.ts.map +1 -0
  64. package/dist/rules/mocha/enable_recommended.js +8 -0
  65. package/dist/rules/mocha/enable_recommended.js.map +1 -0
  66. package/dist/rules/mocha.d.ts +8 -0
  67. package/dist/rules/mocha.d.ts.map +1 -0
  68. package/dist/rules/mocha.js +4 -0
  69. package/dist/rules/mocha.js.map +1 -0
  70. package/dist/rules/svelte/disable.d.ts +5 -0
  71. package/dist/rules/svelte/disable.d.ts.map +1 -0
  72. package/dist/rules/svelte/disable.js +8 -0
  73. package/dist/rules/svelte/disable.js.map +1 -0
  74. package/dist/rules/svelte/disable_js.d.ts.map +1 -1
  75. package/dist/rules/svelte/disable_js.js +8 -3
  76. package/dist/rules/svelte/disable_js.js.map +1 -1
  77. package/dist/rules/svelte/disable_ts.d.ts.map +1 -1
  78. package/dist/rules/svelte/disable_ts.js +8 -3
  79. package/dist/rules/svelte/disable_ts.js.map +1 -1
  80. package/dist/rules/svelte/enable.d.ts +126 -0
  81. package/dist/rules/svelte/enable.d.ts.map +1 -0
  82. package/dist/rules/svelte/enable.js +190 -0
  83. package/dist/rules/svelte/enable.js.map +1 -0
  84. package/dist/rules/svelte/enable_x.d.ts.map +1 -1
  85. package/dist/rules/svelte/enable_x.js +15 -3
  86. package/dist/rules/svelte/enable_x.js.map +1 -1
  87. package/dist/rules/svelte.d.ts +1269 -0
  88. package/dist/rules/svelte.d.ts.map +1 -0
  89. package/dist/rules/svelte.js +15 -0
  90. package/dist/rules/svelte.js.map +1 -0
  91. package/dist/rules/ts/disable.d.ts +18 -0
  92. package/dist/rules/ts/disable.d.ts.map +1 -0
  93. package/dist/rules/ts/disable.js +21 -0
  94. package/dist/rules/ts/disable.js.map +1 -0
  95. package/dist/rules/ts/disable_x.d.ts.map +1 -1
  96. package/dist/rules/ts/disable_x.js +1 -2
  97. package/dist/rules/ts/disable_x.js.map +1 -1
  98. package/dist/rules/ts/enable.d.ts +262 -0
  99. package/dist/rules/ts/enable.d.ts.map +1 -0
  100. package/dist/rules/ts/enable.js +503 -0
  101. package/dist/rules/ts/enable.js.map +1 -0
  102. package/dist/rules/ts/enable_x.d.ts.map +1 -1
  103. package/dist/rules/ts/enable_x.js +32 -5
  104. package/dist/rules/ts/enable_x.js.map +1 -1
  105. package/dist/rules/ts.d.ts +1133 -0
  106. package/dist/rules/ts.d.ts.map +1 -0
  107. package/dist/rules/ts.js +13 -0
  108. package/dist/rules/ts.js.map +1 -0
  109. package/dist/rules/yml/enable.d.ts +39 -0
  110. package/dist/rules/yml/enable.d.ts.map +1 -0
  111. package/dist/rules/yml/enable.js +60 -0
  112. package/dist/rules/yml/enable.js.map +1 -0
  113. package/dist/rules/yml/enable_x.d.ts.map +1 -1
  114. package/dist/rules/yml/enable_x.js +57 -9
  115. package/dist/rules/yml/enable_x.js.map +1 -1
  116. package/dist/rules/yml.d.ts +73 -0
  117. package/dist/rules/yml.d.ts.map +1 -0
  118. package/dist/rules/yml.js +4 -0
  119. package/dist/rules/yml.js.map +1 -0
  120. package/dist/rules.d.ts +75 -75
  121. package/dist/rules.js +9 -9
  122. package/dist/rules.js.map +1 -1
  123. package/eslint.config.js +3 -3
  124. package/package.json +99 -99
  125. package/src/files/html.ts +1 -1
  126. package/src/files/js.ts +1 -1
  127. package/src/files/json.ts +1 -1
  128. package/src/files/jsonc.ts +4 -4
  129. package/src/files/md.ts +1 -1
  130. package/src/files/mocha.ts +1 -1
  131. package/src/files/svelte.ts +1 -1
  132. package/src/files/ts.ts +5 -5
  133. package/src/files/yml.ts +5 -5
  134. package/src/files.ts +22 -22
  135. package/src/imports/parsers.ts +15 -15
  136. package/src/imports/plugins.ts +19 -19
  137. package/src/imports.ts +8 -8
  138. package/src/index.ts +36 -36
  139. package/src/rules/_strings/id.ts +18 -18
  140. package/src/rules/_strings/level.ts +6 -6
  141. package/src/rules/_strings/state.ts +56 -56
  142. package/src/rules/_strings.ts +6 -6
  143. package/src/rules/html/enable.ts +16 -0
  144. package/src/rules/html/enable_recommended.ts +9 -0
  145. package/src/rules/html.ts +4 -0
  146. package/src/rules/js/enable.ts +524 -0
  147. package/src/rules/js/enable_stylistic.ts +608 -0
  148. package/src/rules/js.ts +4 -0
  149. package/src/rules/json/{_enable.ts → enable.ts} +33 -35
  150. package/src/rules/json/enable_x.ts +89 -50
  151. package/src/rules/{_json.ts → json.ts} +4 -4
  152. package/src/rules/jsonc/override.ts +16 -9
  153. package/src/rules/{_jsonc.ts → jsonc.ts} +4 -4
  154. package/src/rules/md/enable.ts +15 -0
  155. package/src/rules/md.ts +3 -0
  156. package/src/rules/mocha/enable.ts +3 -0
  157. package/src/rules/mocha/enable_recommended.ts +9 -0
  158. package/src/rules/mocha.ts +4 -0
  159. package/src/rules/svelte/disable.ts +9 -0
  160. package/src/rules/svelte/disable_js.ts +11 -7
  161. package/src/rules/svelte/disable_ts.ts +9 -5
  162. package/src/rules/svelte/{_enable.ts → enable.ts} +228 -129
  163. package/src/rules/svelte/enable_x.ts +20 -9
  164. package/src/rules/{_svelte.ts → svelte.ts} +15 -15
  165. package/src/rules/ts/{disable_compiler.ts → disable.ts} +22 -23
  166. package/src/rules/ts/disable_x.ts +32 -36
  167. package/src/rules/ts/{_enable.ts → enable.ts} +549 -406
  168. package/src/rules/ts/enable_x.ts +115 -90
  169. package/src/rules/{_ts.ts → ts.ts} +13 -13
  170. package/src/rules/yml/{_enable.ts → enable.ts} +64 -33
  171. package/src/rules/yml/enable_x.ts +68 -21
  172. package/src/rules/{_yml.ts → yml.ts} +4 -4
  173. package/src/rules.ts +22 -22
  174. package/tsconfig.json +161 -161
  175. package/types/markdownlint/index.d.ts +3 -3
  176. package/types/markdownlint/parser.d.ts +9 -9
  177. package/types/mocha/index.d.ts +8 -8
  178. package/src/rules/_html.ts +0 -4
  179. package/src/rules/_js.ts +0 -4
  180. package/src/rules/_md.ts +0 -3
  181. package/src/rules/_mocha.ts +0 -4
  182. package/src/rules/html/_enable.ts +0 -13
  183. package/src/rules/html/_recommended.ts +0 -7
  184. package/src/rules/js/_enable.ts +0 -287
  185. package/src/rules/js/stylistic.ts +0 -294
  186. package/src/rules/md/_enable.ts +0 -14
  187. package/src/rules/mocha/_enable.ts +0 -5
  188. package/src/rules/mocha/_recommended.ts +0 -7
  189. package/src/rules/svelte/disable_x.ts +0 -8
@@ -1,90 +1,115 @@
1
- import { id, level, state } from "../_strings.js";
2
-
3
- const
4
- { enable_x } = id,
5
- { ERROR, OFF } = level,
6
- { Always, All } = state;
7
-
8
- export default [
9
- enable_x,
10
- {
11
-
12
- // https://typescript-eslint.io/rules/?=extension-xdeprecated#rules ]
13
- "@typescript-eslint/class-methods-use-this": OFF, /* preference -- eslint:off */
14
- "@typescript-eslint/consistent-return": OFF, /* tsconfig: noImplicitReturns */
15
- "@typescript-eslint/default-param-last": ERROR,
16
- "@typescript-eslint/dot-notation": [
17
- ERROR,
18
- {
19
- allowKeywords: true,
20
-
21
- // TS-only
22
- allowPrivateClassPropertyAccess: true,
23
- allowProtectedClassPropertyAccess: true,
24
- allowIndexSignaturePropertyAccess: true,
25
- },
26
- ],
27
- "@typescript-eslint/init-declarations": [
28
- ERROR,
29
- Always,
30
- ],
31
- "@typescript-eslint/max-params": OFF /* preference */,
32
- "@typescript-eslint/no-array-constructor": ERROR,
33
- "@typescript-eslint/no-dupe-class-members": OFF /* tsc */,
34
- "@typescript-eslint/no-empty-function": [
35
- ERROR,
36
- {
37
- allow: [
38
- "constructors",
39
- "private-constructors",
40
- "protected-constructors",
41
- "decoratedFunctions",
42
- ],
43
- }, /* functions, arrowFunctions, generatorFunctions, methods, generatorMethods, getters, setters, constructors, asyncFunctions, asyncMethods; TS-ONLY: private-constructors, protected-constructors, decoratedFunctions, overrideMethods */
44
- ],
45
- "@typescript-eslint/no-implied-eval": ERROR,
46
- "@typescript-eslint/no-invalid-this": OFF /* tsconfig: { strict, noImplicitThis } */,
47
- "@typescript-eslint/no-loop-func": ERROR,
48
- "@typescript-eslint/no-magic-numbers": OFF,
49
- "@typescript-eslint/no-redeclare": OFF /* tsc (let, const, -var) */,
50
- "@typescript-eslint/no-restricted-imports": OFF, /* preference */
51
- "@typescript-eslint/no-shadow": OFF, /* investigate */
52
- "@typescript-eslint/no-unused-expressions": [
53
- ERROR,
54
- {
55
- allowShortCircuit: true,
56
- allowTernary: true,
57
- allowTaggedTemplates: true,
58
- enforceForJSX: false,
59
- },
60
- ],
61
- "@typescript-eslint/no-unused-vars": [
62
- ERROR,
63
- {
64
- vars: All,
65
- args: All,
66
- caughtErrors: All,
67
- ignoreRestSiblings: false,
68
- ignoreClassWithStaticInitBlock: false,
69
- reportUsedIgnorePattern: true,
70
- },
71
- ],
72
- "@typescript-eslint/no-use-before-define": [
73
- ERROR,
74
- {
75
- functions: true,
76
- classes: true,
77
- variables: true,
78
- allowNamedExports: false,
79
- enums: true,
80
- typedefs: false, /* changed 14.2.2 (still questionable) */
81
- ignoreTypeReferences: true,
82
- },
83
- ],
84
- "@typescript-eslint/no-useless-constructor": ERROR,
85
- "@typescript-eslint/only-throw-error": [ERROR, { allowThrowingAny: false, allowThrowingUnknown: false }],
86
- "@typescript-eslint/prefer-destructuring": [ERROR, { VariableDeclarator: { array: true, object: true }, AssignmentExpression: { array: false, object: false } }, { enforceForRenamedProperties: false, enforceForDeclarationWithTypeAnnotation: false }],
87
- "@typescript-eslint/prefer-promise-reject-errors": [ERROR, { allowEmptyReject: false }],
88
- "@typescript-eslint/require-await": ERROR,
89
- },
90
- ] as const;
1
+ import { enable_x, level, state } from "../_strings.js";
2
+
3
+ const
4
+ { ERROR, OFF } = level,
5
+ { Always, All } = state;
6
+
7
+ export default [
8
+ enable_x,
9
+ {
10
+ // https://typescript-eslint.io/rules/?=extension-xdeprecated#rules
11
+ "@typescript-eslint/class-methods-use-this": OFF /* preference -- eslint:off */,
12
+ "@typescript-eslint/consistent-return": OFF /* tsconfig: noImplicitReturns */,
13
+ "@typescript-eslint/default-param-last": ERROR,
14
+ "@typescript-eslint/dot-notation": [
15
+ ERROR,
16
+ {
17
+ allowKeywords: true,
18
+
19
+ // TS-only
20
+ allowPrivateClassPropertyAccess: true,
21
+ allowProtectedClassPropertyAccess: true,
22
+ allowIndexSignaturePropertyAccess: true,
23
+ },
24
+ ],
25
+ "@typescript-eslint/init-declarations": [
26
+ ERROR,
27
+ Always,
28
+ ],
29
+ "@typescript-eslint/max-params": OFF /* preference */,
30
+ "@typescript-eslint/no-array-constructor": ERROR,
31
+ "@typescript-eslint/no-dupe-class-members": OFF /* tsc */,
32
+ "@typescript-eslint/no-empty-function": [
33
+ ERROR,
34
+ {
35
+ allow: [
36
+ "constructors",
37
+ "private-constructors",
38
+ "protected-constructors",
39
+ "decoratedFunctions",
40
+ ],
41
+ }, /* functions, arrowFunctions, generatorFunctions, methods, generatorMethods, getters, setters, constructors, asyncFunctions, asyncMethods; TS-ONLY: private-constructors, protected-constructors, decoratedFunctions, overrideMethods */
42
+ ],
43
+ "@typescript-eslint/no-implied-eval": ERROR,
44
+ "@typescript-eslint/no-invalid-this": OFF /* tsconfig: { strict, noImplicitThis } */,
45
+ "@typescript-eslint/no-loop-func": ERROR,
46
+ "@typescript-eslint/no-magic-numbers": OFF,
47
+ "@typescript-eslint/no-redeclare": OFF /* tsc (let, const, -var) */,
48
+ "@typescript-eslint/no-restricted-imports": OFF /* preference */,
49
+ "@typescript-eslint/no-shadow": OFF /* investigate */,
50
+ "@typescript-eslint/no-unused-expressions": [
51
+ ERROR,
52
+ {
53
+ allowShortCircuit: true,
54
+ allowTernary: true,
55
+ allowTaggedTemplates: true,
56
+ enforceForJSX: false,
57
+ },
58
+ ],
59
+ "@typescript-eslint/no-unused-vars": [
60
+ ERROR,
61
+ {
62
+ vars: All,
63
+ args: All,
64
+ caughtErrors: All,
65
+ ignoreRestSiblings: false,
66
+ ignoreClassWithStaticInitBlock: false,
67
+ reportUsedIgnorePattern: true,
68
+ },
69
+ ],
70
+ "@typescript-eslint/no-use-before-define": [
71
+ ERROR,
72
+ {
73
+ functions: true,
74
+ classes: true,
75
+ variables: true,
76
+ allowNamedExports: false,
77
+ enums: true,
78
+ typedefs: false /* changed 14.2.2 (still questionable) */,
79
+ ignoreTypeReferences: true,
80
+ },
81
+ ],
82
+ "@typescript-eslint/no-useless-constructor": ERROR,
83
+ "@typescript-eslint/only-throw-error": [
84
+ ERROR,
85
+ {
86
+ allowThrowingAny: false,
87
+ allowThrowingUnknown: false,
88
+ },
89
+ ],
90
+ "@typescript-eslint/prefer-destructuring": [
91
+ ERROR,
92
+ {
93
+ VariableDeclarator: {
94
+ array: true,
95
+ object: true,
96
+ },
97
+ AssignmentExpression: {
98
+ array: false,
99
+ object: false,
100
+ },
101
+ },
102
+ {
103
+ enforceForRenamedProperties: false,
104
+ enforceForDeclarationWithTypeAnnotation: false,
105
+ },
106
+ ],
107
+ "@typescript-eslint/prefer-promise-reject-errors": [
108
+ ERROR,
109
+ {
110
+ allowEmptyReject: false,
111
+ },
112
+ ],
113
+ "@typescript-eslint/require-await": ERROR,
114
+ },
115
+ ] as const;
@@ -1,13 +1,13 @@
1
- import Js from "./_js.js";
2
- import DisableCompiler from "./ts/disable_compiler.js";
3
- import DisableX from "./ts/disable_x.js";
4
- import EnableX from "./ts/enable_x.js";
5
- import Enable from "./ts/_enable.js";
6
-
7
- export default [
8
- ...Js,
9
- DisableCompiler,
10
- DisableX,
11
- EnableX,
12
- Enable,
13
- ] as const;
1
+ import Js from "./js.js";
2
+ import DisableCompiler from "./ts/disable.js";
3
+ import DisableX from "./ts/disable_x.js";
4
+ import EnableX from "./ts/enable_x.js";
5
+ import Enable from "./ts/enable.js";
6
+
7
+ export default [
8
+ ...Js,
9
+ DisableCompiler,
10
+ DisableX,
11
+ EnableX,
12
+ Enable,
13
+ ] as const;
@@ -1,33 +1,64 @@
1
- import { id, level, state } from "../_strings.js";
2
-
3
- const
4
- { enable } = id,
5
- { ERROR, OFF } = level,
6
- { Never, Always, Double } = state;
7
-
8
- export default [
9
- enable,
10
- {
11
- // https://ota-meshi.github.io/eslint-plugin-yml/rules/#yaml-rules
12
- "yml/block-mapping-colon-indicator-newline": [ERROR, Never],
13
- "yml/block-mapping-question-indicator-newline": [ERROR, Never],
14
- "yml/block-mapping": [ERROR, { singleline: Never, multiline: Always }],
15
- "yml/block-sequence-hyphen-indicator-newline": [ERROR, Never, { nestedHyphen: Always, blockMapping: Never }],
16
- "yml/block-sequence": [ERROR, { singleline: Always, multiline: Always }],
17
- "yml/file-extension": OFF,
18
- "yml/indent": [ERROR, 2, { indentBlockSequences: true, indicatorValueIndent: 2 }],
19
- "yml/key-name-casing": OFF,
20
- "yml/no-empty-document": ERROR,
21
- "yml/no-empty-key": ERROR,
22
- "yml/no-empty-mapping-value": ERROR,
23
- "yml/no-empty-sequence-entry": ERROR,
24
- "yml/no-tab-indent": ERROR,
25
- "yml/no-trailing-zeros": ERROR,
26
- "yml/plain-scalar": [ERROR, Always],
27
- "yml/quotes": [ERROR, { prefer: Double, avoidEscape: true }],
28
- "yml/require-string-key": ERROR,
29
- "yml/sort-keys": OFF,
30
- "yml/sort-sequence-values": OFF,
31
- "yml/vue-custom-block/no-parsing-error": ERROR,
32
- },
33
- ] as const;
1
+ import { enable, level, state } from "../_strings.js";
2
+
3
+ const
4
+ { ERROR, OFF } = level,
5
+ { Never, Always, Double } = state;
6
+
7
+ export default [
8
+ enable,
9
+ {
10
+ // https://ota-meshi.github.io/eslint-plugin-yml/rules/#yaml-rules
11
+ "yml/block-mapping-colon-indicator-newline": [ERROR, Never],
12
+ "yml/block-mapping-question-indicator-newline": [ERROR, Never],
13
+ "yml/block-mapping": [
14
+ ERROR,
15
+ {
16
+ singleline: Never,
17
+ multiline: Always,
18
+ },
19
+ ],
20
+ "yml/block-sequence-hyphen-indicator-newline": [
21
+ ERROR,
22
+ Never,
23
+ {
24
+ nestedHyphen: Always,
25
+ blockMapping: Never,
26
+ },
27
+ ],
28
+ "yml/block-sequence": [
29
+ ERROR,
30
+ {
31
+ singleline: Always,
32
+ multiline: Always,
33
+ },
34
+ ],
35
+ "yml/file-extension": OFF,
36
+ "yml/indent": [
37
+ ERROR,
38
+ 2,
39
+ {
40
+ indentBlockSequences: true,
41
+ indicatorValueIndent: 2,
42
+ },
43
+ ],
44
+ "yml/key-name-casing": OFF,
45
+ "yml/no-empty-document": ERROR,
46
+ "yml/no-empty-key": ERROR,
47
+ "yml/no-empty-mapping-value": ERROR,
48
+ "yml/no-empty-sequence-entry": ERROR,
49
+ "yml/no-tab-indent": ERROR,
50
+ "yml/no-trailing-zeros": ERROR,
51
+ "yml/plain-scalar": [ERROR, Always],
52
+ "yml/quotes": [
53
+ ERROR,
54
+ {
55
+ prefer: Double,
56
+ avoidEscape: true,
57
+ },
58
+ ],
59
+ "yml/require-string-key": ERROR,
60
+ "yml/sort-keys": OFF,
61
+ "yml/sort-sequence-values": OFF,
62
+ "yml/vue-custom-block/no-parsing-error": ERROR,
63
+ },
64
+ ] as const;
@@ -1,21 +1,68 @@
1
- import { id, level, state } from "../_strings.js";
2
-
3
- const
4
- { enable_x } = id,
5
- { ERROR } = level,
6
- { Never, Always, Strict } = state;
7
-
8
- export default [
9
- enable_x,
10
- {
11
- // https://ota-meshi.github.io/eslint-plugin-yml/rules/#extension-rules
12
- "yml/flow-mapping-curly-newline": [ERROR, { consistent: false, multiline: true, minProperties: 2 }],
13
- "yml/flow-mapping-curly-spacing": [ERROR, Always, { arraysInObjects: true, objectsInObjects: true }],
14
- "yml/flow-sequence-bracket-newline": [ERROR, { multiline: true, minItems: null }],
15
- "yml/flow-sequence-bracket-spacing": [ERROR, Never, { singleValue: false, objectsInArrays: false, arraysInArrays: false }],
16
- "yml/key-spacing": [ERROR, { beforeColon: false, afterColon: true, mode: Strict }],
17
- "yml/no-irregular-whitespace": [ERROR, { skipQuotedScalars: true, skipComments: false }],
18
- "yml/no-multiple-empty-lines": [ERROR, { max: 1, maxEOF: 1, maxBOF: 0 }],
19
- "yml/spaced-comment": [ERROR, Always],
20
- },
21
- ] as const;
1
+ import { enable_x, level, state } from "../_strings.js";
2
+
3
+ const
4
+ { ERROR } = level,
5
+ { Never, Always, Strict } = state;
6
+
7
+ export default [
8
+ enable_x,
9
+ {
10
+ // https://ota-meshi.github.io/eslint-plugin-yml/rules/#extension-rules
11
+ "yml/flow-mapping-curly-newline": [
12
+ ERROR,
13
+ {
14
+ consistent: false,
15
+ multiline: true,
16
+ minProperties: 2,
17
+ },
18
+ ],
19
+ "yml/flow-mapping-curly-spacing": [
20
+ ERROR,
21
+ Always,
22
+ {
23
+ arraysInObjects: true,
24
+ objectsInObjects: true,
25
+ },
26
+ ],
27
+ "yml/flow-sequence-bracket-newline": [
28
+ ERROR,
29
+ {
30
+ multiline: true,
31
+ minItems: null,
32
+ },
33
+ ],
34
+ "yml/flow-sequence-bracket-spacing": [
35
+ ERROR,
36
+ Never,
37
+ {
38
+ singleValue: false,
39
+ objectsInArrays: false,
40
+ arraysInArrays: false,
41
+ },
42
+ ],
43
+ "yml/key-spacing": [
44
+ ERROR,
45
+ {
46
+ beforeColon: false,
47
+ afterColon: true,
48
+ mode: Strict,
49
+ },
50
+ ],
51
+ "yml/no-irregular-whitespace": [
52
+ ERROR,
53
+ {
54
+ skipQuotedScalars: true,
55
+ skipComments: false,
56
+ },
57
+ ],
58
+ "yml/no-multiple-empty-lines": [
59
+ ERROR,
60
+ {
61
+ max: 1,
62
+ maxEOF: 1,
63
+ maxBOF: 0,
64
+ },
65
+ ],
66
+ "yml/spaced-comment": [ERROR, Always],
67
+ },
68
+ ] as const;
@@ -1,4 +1,4 @@
1
- import EnableX from "./yml/enable_x.js";
2
- import Enable from "./yml/_enable.js";
3
-
4
- export default [EnableX, Enable] as const;
1
+ import EnableX from "./yml/enable_x.js";
2
+ import Enable from "./yml/enable.js";
3
+
4
+ export default [EnableX, Enable] as const;
package/src/rules.ts CHANGED
@@ -1,22 +1,22 @@
1
- import type { Core } from "@eslinted/core";
2
- import js from "./rules/_js.js";
3
- import ts from "./rules/_ts.js";
4
- import svelte from "./rules/_svelte.js";
5
- import mocha from "./rules/_mocha.js";
6
- import html from "./rules/_html.js";
7
- import json from "./rules/_json.js";
8
- import jsonc from "./rules/_jsonc.js";
9
- import yml from "./rules/_yml.js";
10
- import md from "./rules/_md.js";
11
-
12
- export default {
13
- js,
14
- ts,
15
- svelte,
16
- mocha,
17
- html,
18
- json,
19
- jsonc,
20
- yml,
21
- md,
22
- } as const satisfies Core.Input.Rules.Base;
1
+ import type { Core } from "@eslinted/core";
2
+ import js from "./rules/js.js";
3
+ import ts from "./rules/ts.js";
4
+ import svelte from "./rules/svelte.js";
5
+ import mocha from "./rules/mocha.js";
6
+ import html from "./rules/html.js";
7
+ import json from "./rules/json.js";
8
+ import jsonc from "./rules/jsonc.js";
9
+ import yml from "./rules/yml.js";
10
+ import md from "./rules/md.js";
11
+
12
+ export default {
13
+ js,
14
+ ts,
15
+ svelte,
16
+ mocha,
17
+ html,
18
+ json,
19
+ jsonc,
20
+ yml,
21
+ md,
22
+ } as const satisfies Core.Input.Rules.Base;