@azat-io/eslint-config 2.72.0 → 2.74.0
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/a11y/index.js +43 -51
- package/dist/astro/index.js +82 -96
- package/dist/core/index.js +541 -652
- package/dist/index.js +61 -79
- package/dist/node/index.js +44 -56
- package/dist/package-json/index.js +48 -66
- package/dist/perfectionist/index.js +47 -63
- package/dist/qwik/index.js +22 -30
- package/dist/react/index.js +103 -130
- package/dist/svelte/index.js +74 -88
- package/dist/typescript/index.js +188 -247
- package/dist/utilities.js +11 -17
- package/dist/vitest/index.js +63 -84
- package/dist/vue/index.js +177 -202
- package/package.json +14 -15
- package/readme.md +0 -1
package/dist/vue/index.js
CHANGED
|
@@ -1,205 +1,180 @@
|
|
|
1
1
|
import { interopDefault } from "../utilities.js";
|
|
2
2
|
async function vue(config) {
|
|
3
|
-
|
|
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
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
"vue/valid-define-options": "error",
|
|
180
|
-
"vue/valid-define-props": "error",
|
|
181
|
-
"vue/valid-next-tick": "error",
|
|
182
|
-
"vue/valid-template-root": "error",
|
|
183
|
-
"vue/valid-v-bind": "error",
|
|
184
|
-
"vue/valid-v-cloak": "error",
|
|
185
|
-
"vue/valid-v-else": "error",
|
|
186
|
-
"vue/valid-v-else-if": "error",
|
|
187
|
-
"vue/valid-v-for": "error",
|
|
188
|
-
"vue/valid-v-html": "error",
|
|
189
|
-
"vue/valid-v-if": "error",
|
|
190
|
-
"vue/valid-v-is": "error",
|
|
191
|
-
"vue/valid-v-memo": "error",
|
|
192
|
-
"vue/valid-v-model": "error",
|
|
193
|
-
"vue/valid-v-on": "error",
|
|
194
|
-
"vue/valid-v-once": "error",
|
|
195
|
-
"vue/valid-v-pre": "error",
|
|
196
|
-
"vue/valid-v-show": "error",
|
|
197
|
-
"vue/valid-v-slot": "error",
|
|
198
|
-
"vue/valid-v-text": "error"
|
|
199
|
-
},
|
|
200
|
-
processor: vuePlugin.processors[".vue"]
|
|
201
|
-
};
|
|
3
|
+
if (!config.vue) return {};
|
|
4
|
+
let [vuePlugin, vueParser] = await Promise.all([interopDefault(import("eslint-plugin-vue")), interopDefault(import("vue-eslint-parser"))]);
|
|
5
|
+
let files = ["**/*.vue"];
|
|
6
|
+
let additionalParserOptions = {};
|
|
7
|
+
if (config.typescript) {
|
|
8
|
+
let { parser: typescriptParser } = await interopDefault(import("typescript-eslint"));
|
|
9
|
+
additionalParserOptions = {
|
|
10
|
+
...additionalParserOptions,
|
|
11
|
+
parser: typescriptParser,
|
|
12
|
+
projectService: true,
|
|
13
|
+
tsconfigRootDir: process.cwd()
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
return {
|
|
17
|
+
name: "azat-io/vue/rules",
|
|
18
|
+
files,
|
|
19
|
+
languageOptions: {
|
|
20
|
+
parser: vueParser,
|
|
21
|
+
parserOptions: {
|
|
22
|
+
ecmaVersion: "latest",
|
|
23
|
+
extraFileExtensions: [".vue"],
|
|
24
|
+
sourceType: "module",
|
|
25
|
+
...additionalParserOptions
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
plugins: { vue: vuePlugin },
|
|
29
|
+
rules: {
|
|
30
|
+
"vue/attribute-hyphenation": ["error", "always"],
|
|
31
|
+
"vue/block-order": ["error", { order: [
|
|
32
|
+
"script",
|
|
33
|
+
"template",
|
|
34
|
+
"style"
|
|
35
|
+
] }],
|
|
36
|
+
"vue/comment-directive": "error",
|
|
37
|
+
"vue/component-api-style": "error",
|
|
38
|
+
"vue/component-definition-name-casing": ["error", "kebab-case"],
|
|
39
|
+
"vue/component-name-in-template-casing": ["error", "kebab-case"],
|
|
40
|
+
"vue/component-options-name-casing": ["error", "kebab-case"],
|
|
41
|
+
"vue/custom-event-name-casing": ["error", "kebab-case"],
|
|
42
|
+
"vue/define-emits-declaration": "error",
|
|
43
|
+
"vue/define-props-declaration": "error",
|
|
44
|
+
"vue/define-props-destructuring": ["error", { destructure: "always" }],
|
|
45
|
+
"vue/enforce-style-attribute": ["error", { allow: ["scoped", "plain"] }],
|
|
46
|
+
"vue/html-button-has-type": "error",
|
|
47
|
+
"vue/html-end-tags": "error",
|
|
48
|
+
"vue/jsx-uses-vars": "error",
|
|
49
|
+
"vue/no-async-in-computed-properties": "error",
|
|
50
|
+
"vue/no-child-content": "error",
|
|
51
|
+
"vue/no-computed-properties-in-data": "error",
|
|
52
|
+
"vue/no-deprecated-data-object-declaration": "error",
|
|
53
|
+
"vue/no-deprecated-delete-set": "error",
|
|
54
|
+
"vue/no-deprecated-destroyed-lifecycle": "error",
|
|
55
|
+
"vue/no-deprecated-dollar-listeners-api": "error",
|
|
56
|
+
"vue/no-deprecated-dollar-scopedslots-api": "error",
|
|
57
|
+
"vue/no-deprecated-events-api": "error",
|
|
58
|
+
"vue/no-deprecated-filter": "error",
|
|
59
|
+
"vue/no-deprecated-functional-template": "error",
|
|
60
|
+
"vue/no-deprecated-html-element-is": "error",
|
|
61
|
+
"vue/no-deprecated-inline-template": "error",
|
|
62
|
+
"vue/no-deprecated-model-definition": "error",
|
|
63
|
+
"vue/no-deprecated-props-default-this": "error",
|
|
64
|
+
"vue/no-deprecated-router-link-tag-prop": "error",
|
|
65
|
+
"vue/no-deprecated-scope-attribute": "error",
|
|
66
|
+
"vue/no-deprecated-slot-attribute": "error",
|
|
67
|
+
"vue/no-deprecated-slot-scope-attribute": "error",
|
|
68
|
+
"vue/no-deprecated-v-bind-sync": "error",
|
|
69
|
+
"vue/no-deprecated-v-is": "error",
|
|
70
|
+
"vue/no-deprecated-v-on-native-modifier": "error",
|
|
71
|
+
"vue/no-deprecated-v-on-number-modifiers": "error",
|
|
72
|
+
"vue/no-deprecated-vue-config-keycodes": "error",
|
|
73
|
+
"vue/no-dupe-keys": "error",
|
|
74
|
+
"vue/no-dupe-v-else-if": "error",
|
|
75
|
+
"vue/no-duplicate-attr-inheritance": "error",
|
|
76
|
+
"vue/no-duplicate-attributes": "error",
|
|
77
|
+
"vue/no-duplicate-class-names": "error",
|
|
78
|
+
"vue/no-empty-component-block": "error",
|
|
79
|
+
"vue/no-export-in-script-setup": "error",
|
|
80
|
+
"vue/no-expose-after-await": "error",
|
|
81
|
+
"vue/no-lifecycle-after-await": "error",
|
|
82
|
+
"vue/no-literals-in-template": "error",
|
|
83
|
+
"vue/no-lone-template": "error",
|
|
84
|
+
"vue/no-multiple-objects-in-class": "error",
|
|
85
|
+
"vue/no-multiple-slot-args": "error",
|
|
86
|
+
"vue/no-mutating-props": "error",
|
|
87
|
+
"vue/no-negated-condition": "error",
|
|
88
|
+
"vue/no-negated-v-if-condition": "error",
|
|
89
|
+
"vue/no-parsing-error": "error",
|
|
90
|
+
"vue/no-potential-component-option-typo": "error",
|
|
91
|
+
"vue/no-ref-as-operand": "error",
|
|
92
|
+
"vue/no-ref-object-reactivity-loss": "error",
|
|
93
|
+
"vue/no-required-prop-with-default": "error",
|
|
94
|
+
"vue/no-reserved-component-names": "error",
|
|
95
|
+
"vue/no-reserved-keys": "error",
|
|
96
|
+
"vue/no-reserved-props": "error",
|
|
97
|
+
"vue/no-setup-props-reactivity-loss": "error",
|
|
98
|
+
"vue/no-shared-component-data": "error",
|
|
99
|
+
"vue/no-side-effects-in-computed-properties": "error",
|
|
100
|
+
"vue/no-template-key": "error",
|
|
101
|
+
"vue/no-template-shadow": "error",
|
|
102
|
+
"vue/no-template-target-blank": "error",
|
|
103
|
+
"vue/no-textarea-mustache": "error",
|
|
104
|
+
"vue/no-this-in-before-route-enter": "error",
|
|
105
|
+
"vue/no-undef-components": "error",
|
|
106
|
+
"vue/no-undef-directives": "error",
|
|
107
|
+
"vue/no-undef-properties": "error",
|
|
108
|
+
"vue/no-unused-components": "error",
|
|
109
|
+
"vue/no-unused-emit-declarations": "error",
|
|
110
|
+
"vue/no-unused-vars": "error",
|
|
111
|
+
"vue/no-use-computed-property-like-method": "error",
|
|
112
|
+
"vue/no-use-v-else-with-v-for": "error",
|
|
113
|
+
"vue/no-use-v-if-with-v-for": "error",
|
|
114
|
+
"vue/no-useless-mustaches": "error",
|
|
115
|
+
"vue/no-useless-template-attributes": "error",
|
|
116
|
+
"vue/no-useless-v-bind": "error",
|
|
117
|
+
"vue/no-v-for-template-key-on-child": "error",
|
|
118
|
+
"vue/no-v-html": "error",
|
|
119
|
+
"vue/no-v-text-v-html-on-component": "error",
|
|
120
|
+
"vue/no-watch-after-await": "error",
|
|
121
|
+
"vue/prefer-define-options": "error",
|
|
122
|
+
"vue/prefer-import-from-vue": "error",
|
|
123
|
+
"vue/prefer-separate-static-class": "error",
|
|
124
|
+
"vue/prefer-true-attribute-shorthand": "error",
|
|
125
|
+
"vue/prop-name-casing": ["error", "camelCase"],
|
|
126
|
+
"vue/require-component-is": "error",
|
|
127
|
+
"vue/require-default-prop": "error",
|
|
128
|
+
"vue/require-emit-validator": "error",
|
|
129
|
+
"vue/require-explicit-emits": "error",
|
|
130
|
+
"vue/require-explicit-slots": "error",
|
|
131
|
+
"vue/require-macro-variable-name": ["error", {
|
|
132
|
+
defineEmits: "emit",
|
|
133
|
+
defineProps: "props",
|
|
134
|
+
defineSlots: "slots",
|
|
135
|
+
useAttrs: "attrs",
|
|
136
|
+
useSlots: "slots"
|
|
137
|
+
}],
|
|
138
|
+
"vue/require-name-property": "error",
|
|
139
|
+
"vue/require-prop-type-constructor": "error",
|
|
140
|
+
"vue/require-render-return": "error",
|
|
141
|
+
"vue/require-slots-as-functions": "error",
|
|
142
|
+
"vue/require-toggle-inside-transition": "error",
|
|
143
|
+
"vue/require-typed-ref": "error",
|
|
144
|
+
"vue/require-v-for-key": "error",
|
|
145
|
+
"vue/require-valid-default-prop": "error",
|
|
146
|
+
"vue/return-in-computed-property": "error",
|
|
147
|
+
"vue/return-in-emits-validator": "error",
|
|
148
|
+
"vue/this-in-template": "error",
|
|
149
|
+
"vue/use-v-on-exact": "error",
|
|
150
|
+
"vue/v-bind-style": "error",
|
|
151
|
+
"vue/v-on-event-hyphenation": "error",
|
|
152
|
+
"vue/v-on-style": "error",
|
|
153
|
+
"vue/v-slot-style": "error",
|
|
154
|
+
"vue/valid-attribute-name": "error",
|
|
155
|
+
"vue/valid-define-emits": "error",
|
|
156
|
+
"vue/valid-define-options": "error",
|
|
157
|
+
"vue/valid-define-props": "error",
|
|
158
|
+
"vue/valid-next-tick": "error",
|
|
159
|
+
"vue/valid-template-root": "error",
|
|
160
|
+
"vue/valid-v-bind": "error",
|
|
161
|
+
"vue/valid-v-cloak": "error",
|
|
162
|
+
"vue/valid-v-else": "error",
|
|
163
|
+
"vue/valid-v-else-if": "error",
|
|
164
|
+
"vue/valid-v-for": "error",
|
|
165
|
+
"vue/valid-v-html": "error",
|
|
166
|
+
"vue/valid-v-if": "error",
|
|
167
|
+
"vue/valid-v-is": "error",
|
|
168
|
+
"vue/valid-v-memo": "error",
|
|
169
|
+
"vue/valid-v-model": "error",
|
|
170
|
+
"vue/valid-v-on": "error",
|
|
171
|
+
"vue/valid-v-once": "error",
|
|
172
|
+
"vue/valid-v-pre": "error",
|
|
173
|
+
"vue/valid-v-show": "error",
|
|
174
|
+
"vue/valid-v-slot": "error",
|
|
175
|
+
"vue/valid-v-text": "error"
|
|
176
|
+
},
|
|
177
|
+
processor: vuePlugin.processors[".vue"]
|
|
178
|
+
};
|
|
202
179
|
}
|
|
203
|
-
export {
|
|
204
|
-
vue
|
|
205
|
-
};
|
|
180
|
+
export { vue };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@azat-io/eslint-config",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.74.0",
|
|
4
4
|
"description": "ESLint shareable config",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eslint",
|
|
@@ -28,38 +28,37 @@
|
|
|
28
28
|
],
|
|
29
29
|
"dependencies": {
|
|
30
30
|
"@eslint-community/eslint-plugin-eslint-comments": "^4.7.1",
|
|
31
|
-
"@vitest/eslint-plugin": "1.6.
|
|
31
|
+
"@vitest/eslint-plugin": "1.6.13",
|
|
32
32
|
"astro-eslint-parser": "^1.3.0",
|
|
33
33
|
"eslint-config-flat-gitignore": "^2.2.1",
|
|
34
34
|
"eslint-plugin-astro": "^1.6.0",
|
|
35
35
|
"eslint-plugin-de-morgan": "^2.1.1",
|
|
36
36
|
"eslint-plugin-depend": "^1.5.0",
|
|
37
|
-
"eslint-plugin-import-lite": "^0.
|
|
38
|
-
"eslint-plugin-jsdoc": "^62.
|
|
37
|
+
"eslint-plugin-import-lite": "^0.6.0",
|
|
38
|
+
"eslint-plugin-jsdoc": "^62.8.0",
|
|
39
39
|
"eslint-plugin-jsx-a11y": "^6.10.2",
|
|
40
40
|
"eslint-plugin-n": "^17.24.0",
|
|
41
|
-
"eslint-plugin-package-json": "^0.
|
|
42
|
-
"eslint-plugin-perfectionist": "^5.
|
|
43
|
-
"eslint-plugin-prefer-let": "^4.
|
|
41
|
+
"eslint-plugin-package-json": "^0.91.0",
|
|
42
|
+
"eslint-plugin-perfectionist": "^5.7.0",
|
|
43
|
+
"eslint-plugin-prefer-let": "^4.2.0",
|
|
44
44
|
"eslint-plugin-promise": "^7.2.1",
|
|
45
45
|
"eslint-plugin-qwik": "2.0.0-beta.21",
|
|
46
46
|
"eslint-plugin-react-compiler": "19.1.0-rc.2",
|
|
47
|
-
"eslint-plugin-react-dom": "^
|
|
47
|
+
"eslint-plugin-react-dom": "^3.0.0",
|
|
48
48
|
"eslint-plugin-react-hooks": "^7.0.1",
|
|
49
|
-
"eslint-plugin-react-
|
|
50
|
-
"eslint-plugin-react-naming-convention": "^2.13.0",
|
|
49
|
+
"eslint-plugin-react-naming-convention": "^3.0.0",
|
|
51
50
|
"eslint-plugin-react-perf": "^3.3.3",
|
|
52
|
-
"eslint-plugin-react-web-api": "^
|
|
53
|
-
"eslint-plugin-react-x": "^
|
|
51
|
+
"eslint-plugin-react-web-api": "^3.0.0",
|
|
52
|
+
"eslint-plugin-react-x": "^3.0.0",
|
|
54
53
|
"eslint-plugin-regexp": "^3.1.0",
|
|
55
|
-
"eslint-plugin-sonarjs": "^4.0.
|
|
56
|
-
"eslint-plugin-svelte": "^3.
|
|
54
|
+
"eslint-plugin-sonarjs": "^4.0.2",
|
|
55
|
+
"eslint-plugin-svelte": "^3.16.0",
|
|
57
56
|
"eslint-plugin-unicorn": "^63.0.0",
|
|
58
57
|
"eslint-plugin-vue": "^10.8.0",
|
|
59
58
|
"globals": "^17.4.0",
|
|
60
59
|
"jsonc-eslint-parser": "^3.1.0",
|
|
61
60
|
"svelte-eslint-parser": "^1.6.0",
|
|
62
|
-
"typescript-eslint": "^8.57.
|
|
61
|
+
"typescript-eslint": "^8.57.1",
|
|
63
62
|
"vue-eslint-parser": "^10.4.0"
|
|
64
63
|
},
|
|
65
64
|
"peerDependencies": {
|
package/readme.md
CHANGED
|
@@ -153,7 +153,6 @@ This config uses the following plugins:
|
|
|
153
153
|
- [eslint-plugin-react-compiler](https://github.com/facebook/react/tree/main/compiler/packages/eslint-plugin-react-compiler)
|
|
154
154
|
- [eslint-plugin-react-dom](https://github.com/Rel1cx/eslint-react)
|
|
155
155
|
- [eslint-plugin-react-hooks](https://github.com/facebook/react/tree/main/packages/eslint-plugin-react-hooks)
|
|
156
|
-
- [eslint-plugin-react-hooks-extra](https://github.com/Rel1cx/eslint-react)
|
|
157
156
|
- [eslint-plugin-react-naming-convention](https://github.com/Rel1cx/eslint-react)
|
|
158
157
|
- [eslint-plugin-react-perf](https://github.com/cvazac/eslint-plugin-react-perf)
|
|
159
158
|
- [eslint-plugin-react-web-api](https://github.com/Rel1cx/eslint-react)
|