@saasmakers/eslint 0.1.9 → 0.1.11
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/eslint.config.cjs +6 -39
- package/dist/eslint.config.d.cts +6 -39
- package/dist/eslint.config.d.mts +6 -39
- package/dist/eslint.config.d.ts +6 -39
- package/dist/eslint.config.mjs +6 -39
- package/dist/index.cjs +7 -7
- package/dist/index.mjs +7 -7
- package/package.json +1 -1
package/dist/eslint.config.cjs
CHANGED
|
@@ -16,6 +16,10 @@ const storybook__default = /*#__PURE__*/_interopDefaultCompat(storybook);
|
|
|
16
16
|
|
|
17
17
|
const eslint_config = antfu__default(
|
|
18
18
|
{
|
|
19
|
+
regexp: false,
|
|
20
|
+
typescript: true,
|
|
21
|
+
unocss: true,
|
|
22
|
+
vue: true,
|
|
19
23
|
ignores: [
|
|
20
24
|
"*.md",
|
|
21
25
|
"**/.nuxt",
|
|
@@ -27,11 +31,7 @@ const eslint_config = antfu__default(
|
|
|
27
31
|
"**/dumps/*.json",
|
|
28
32
|
"**/ios",
|
|
29
33
|
"node_modules"
|
|
30
|
-
]
|
|
31
|
-
regexp: false,
|
|
32
|
-
typescript: true,
|
|
33
|
-
unocss: true,
|
|
34
|
-
vue: true
|
|
34
|
+
]
|
|
35
35
|
},
|
|
36
36
|
{
|
|
37
37
|
languageOptions: {
|
|
@@ -73,18 +73,7 @@ const eslint_config = antfu__default(
|
|
|
73
73
|
min: 2
|
|
74
74
|
}
|
|
75
75
|
],
|
|
76
|
-
"no-console": "off",
|
|
77
|
-
"no-control-regex": "off",
|
|
78
|
-
"no-labels": "off",
|
|
79
|
-
"no-restricted-globals": "off",
|
|
80
|
-
// Fix
|
|
81
|
-
"no-restricted-syntax": "off",
|
|
82
|
-
"no-throw-literal": "off",
|
|
83
|
-
// Fix
|
|
84
|
-
"no-unmodified-loop-condition": "off",
|
|
85
|
-
// Fix
|
|
86
76
|
"no-use-before-define": "off",
|
|
87
|
-
"no-var": "off",
|
|
88
77
|
"node/prefer-global/buffer": ["error", "always"],
|
|
89
78
|
"node/prefer-global/process": ["error", "always"],
|
|
90
79
|
"object-curly-newline": [
|
|
@@ -176,7 +165,6 @@ const eslint_config = antfu__default(
|
|
|
176
165
|
}
|
|
177
166
|
],
|
|
178
167
|
"perfectionist/sort-union-types": ["error", { type: "natural" }],
|
|
179
|
-
"prefer-regex-literals": "off",
|
|
180
168
|
"quotes": [
|
|
181
169
|
"error",
|
|
182
170
|
"single",
|
|
@@ -209,22 +197,6 @@ const eslint_config = antfu__default(
|
|
|
209
197
|
"saasmakers/vue-template-format-props": "error",
|
|
210
198
|
"saasmakers/vue-template-remove-comments": "error",
|
|
211
199
|
"saasmakers/vue-template-remove-true-attributes": "error",
|
|
212
|
-
"sort-imports": "off",
|
|
213
|
-
"ts/ban-ts-comment": "off",
|
|
214
|
-
"ts/ban-ts-ignore": "off",
|
|
215
|
-
"ts/ban-types": "off",
|
|
216
|
-
"ts/explicit-member-accessibility": "off",
|
|
217
|
-
"ts/no-explicit-any": "error",
|
|
218
|
-
"ts/no-invalid-this": "off",
|
|
219
|
-
"ts/no-namespace": "off",
|
|
220
|
-
"ts/no-require-imports": "off",
|
|
221
|
-
"ts/no-shadow": "off",
|
|
222
|
-
"ts/no-unused-expressions": "off",
|
|
223
|
-
"ts/no-use-before-define": "off",
|
|
224
|
-
"ts/no-var-requires": "off",
|
|
225
|
-
"ts/prefer-nullish-coalescing": "error",
|
|
226
|
-
"unicorn/filename-case": "off",
|
|
227
|
-
"vars-on-top": "off",
|
|
228
200
|
"vue/attributes-order": [
|
|
229
201
|
"error",
|
|
230
202
|
{
|
|
@@ -256,7 +228,6 @@ const eslint_config = antfu__default(
|
|
|
256
228
|
singleline: "beside"
|
|
257
229
|
}
|
|
258
230
|
],
|
|
259
|
-
// 'vue/define-macros-order': 'off',
|
|
260
231
|
"vue/max-attributes-per-line": [
|
|
261
232
|
"error",
|
|
262
233
|
{
|
|
@@ -272,7 +243,6 @@ const eslint_config = antfu__default(
|
|
|
272
243
|
ignoreWhenEmpty: true
|
|
273
244
|
}
|
|
274
245
|
],
|
|
275
|
-
"vue/no-side-effects-in-computed-properties": "off",
|
|
276
246
|
"vue/padding-line-between-tags": [
|
|
277
247
|
"error",
|
|
278
248
|
[
|
|
@@ -282,10 +252,7 @@ const eslint_config = antfu__default(
|
|
|
282
252
|
prev: "*"
|
|
283
253
|
}
|
|
284
254
|
]
|
|
285
|
-
]
|
|
286
|
-
"vue/return-in-computed-property": "off",
|
|
287
|
-
// This conflicts with another rule that removes empty `return` statements
|
|
288
|
-
"vue/singleline-html-element-content-newline": "off"
|
|
255
|
+
]
|
|
289
256
|
}
|
|
290
257
|
}
|
|
291
258
|
);
|
package/dist/eslint.config.d.cts
CHANGED
|
@@ -5,6 +5,10 @@ import storybook from 'eslint-plugin-storybook';
|
|
|
5
5
|
|
|
6
6
|
var eslint_config = antfu(
|
|
7
7
|
{
|
|
8
|
+
regexp: false,
|
|
9
|
+
typescript: true,
|
|
10
|
+
unocss: true,
|
|
11
|
+
vue: true,
|
|
8
12
|
ignores: [
|
|
9
13
|
"*.md",
|
|
10
14
|
"**/.nuxt",
|
|
@@ -16,11 +20,7 @@ var eslint_config = antfu(
|
|
|
16
20
|
"**/dumps/*.json",
|
|
17
21
|
"**/ios",
|
|
18
22
|
"node_modules"
|
|
19
|
-
]
|
|
20
|
-
regexp: false,
|
|
21
|
-
typescript: true,
|
|
22
|
-
unocss: true,
|
|
23
|
-
vue: true
|
|
23
|
+
]
|
|
24
24
|
},
|
|
25
25
|
{
|
|
26
26
|
languageOptions: {
|
|
@@ -62,18 +62,7 @@ var eslint_config = antfu(
|
|
|
62
62
|
min: 2
|
|
63
63
|
}
|
|
64
64
|
],
|
|
65
|
-
"no-console": "off",
|
|
66
|
-
"no-control-regex": "off",
|
|
67
|
-
"no-labels": "off",
|
|
68
|
-
"no-restricted-globals": "off",
|
|
69
|
-
// Fix
|
|
70
|
-
"no-restricted-syntax": "off",
|
|
71
|
-
"no-throw-literal": "off",
|
|
72
|
-
// Fix
|
|
73
|
-
"no-unmodified-loop-condition": "off",
|
|
74
|
-
// Fix
|
|
75
65
|
"no-use-before-define": "off",
|
|
76
|
-
"no-var": "off",
|
|
77
66
|
"node/prefer-global/buffer": ["error", "always"],
|
|
78
67
|
"node/prefer-global/process": ["error", "always"],
|
|
79
68
|
"object-curly-newline": [
|
|
@@ -165,7 +154,6 @@ var eslint_config = antfu(
|
|
|
165
154
|
}
|
|
166
155
|
],
|
|
167
156
|
"perfectionist/sort-union-types": ["error", { type: "natural" }],
|
|
168
|
-
"prefer-regex-literals": "off",
|
|
169
157
|
"quotes": [
|
|
170
158
|
"error",
|
|
171
159
|
"single",
|
|
@@ -198,22 +186,6 @@ var eslint_config = antfu(
|
|
|
198
186
|
"saasmakers/vue-template-format-props": "error",
|
|
199
187
|
"saasmakers/vue-template-remove-comments": "error",
|
|
200
188
|
"saasmakers/vue-template-remove-true-attributes": "error",
|
|
201
|
-
"sort-imports": "off",
|
|
202
|
-
"ts/ban-ts-comment": "off",
|
|
203
|
-
"ts/ban-ts-ignore": "off",
|
|
204
|
-
"ts/ban-types": "off",
|
|
205
|
-
"ts/explicit-member-accessibility": "off",
|
|
206
|
-
"ts/no-explicit-any": "error",
|
|
207
|
-
"ts/no-invalid-this": "off",
|
|
208
|
-
"ts/no-namespace": "off",
|
|
209
|
-
"ts/no-require-imports": "off",
|
|
210
|
-
"ts/no-shadow": "off",
|
|
211
|
-
"ts/no-unused-expressions": "off",
|
|
212
|
-
"ts/no-use-before-define": "off",
|
|
213
|
-
"ts/no-var-requires": "off",
|
|
214
|
-
"ts/prefer-nullish-coalescing": "error",
|
|
215
|
-
"unicorn/filename-case": "off",
|
|
216
|
-
"vars-on-top": "off",
|
|
217
189
|
"vue/attributes-order": [
|
|
218
190
|
"error",
|
|
219
191
|
{
|
|
@@ -245,7 +217,6 @@ var eslint_config = antfu(
|
|
|
245
217
|
singleline: "beside"
|
|
246
218
|
}
|
|
247
219
|
],
|
|
248
|
-
// 'vue/define-macros-order': 'off',
|
|
249
220
|
"vue/max-attributes-per-line": [
|
|
250
221
|
"error",
|
|
251
222
|
{
|
|
@@ -261,7 +232,6 @@ var eslint_config = antfu(
|
|
|
261
232
|
ignoreWhenEmpty: true
|
|
262
233
|
}
|
|
263
234
|
],
|
|
264
|
-
"vue/no-side-effects-in-computed-properties": "off",
|
|
265
235
|
"vue/padding-line-between-tags": [
|
|
266
236
|
"error",
|
|
267
237
|
[
|
|
@@ -271,10 +241,7 @@ var eslint_config = antfu(
|
|
|
271
241
|
prev: "*"
|
|
272
242
|
}
|
|
273
243
|
]
|
|
274
|
-
]
|
|
275
|
-
"vue/return-in-computed-property": "off",
|
|
276
|
-
// This conflicts with another rule that removes empty `return` statements
|
|
277
|
-
"vue/singleline-html-element-content-newline": "off"
|
|
244
|
+
]
|
|
278
245
|
}
|
|
279
246
|
}
|
|
280
247
|
);
|
package/dist/eslint.config.d.mts
CHANGED
|
@@ -5,6 +5,10 @@ import storybook from 'eslint-plugin-storybook';
|
|
|
5
5
|
|
|
6
6
|
var eslint_config = antfu(
|
|
7
7
|
{
|
|
8
|
+
regexp: false,
|
|
9
|
+
typescript: true,
|
|
10
|
+
unocss: true,
|
|
11
|
+
vue: true,
|
|
8
12
|
ignores: [
|
|
9
13
|
"*.md",
|
|
10
14
|
"**/.nuxt",
|
|
@@ -16,11 +20,7 @@ var eslint_config = antfu(
|
|
|
16
20
|
"**/dumps/*.json",
|
|
17
21
|
"**/ios",
|
|
18
22
|
"node_modules"
|
|
19
|
-
]
|
|
20
|
-
regexp: false,
|
|
21
|
-
typescript: true,
|
|
22
|
-
unocss: true,
|
|
23
|
-
vue: true
|
|
23
|
+
]
|
|
24
24
|
},
|
|
25
25
|
{
|
|
26
26
|
languageOptions: {
|
|
@@ -62,18 +62,7 @@ var eslint_config = antfu(
|
|
|
62
62
|
min: 2
|
|
63
63
|
}
|
|
64
64
|
],
|
|
65
|
-
"no-console": "off",
|
|
66
|
-
"no-control-regex": "off",
|
|
67
|
-
"no-labels": "off",
|
|
68
|
-
"no-restricted-globals": "off",
|
|
69
|
-
// Fix
|
|
70
|
-
"no-restricted-syntax": "off",
|
|
71
|
-
"no-throw-literal": "off",
|
|
72
|
-
// Fix
|
|
73
|
-
"no-unmodified-loop-condition": "off",
|
|
74
|
-
// Fix
|
|
75
65
|
"no-use-before-define": "off",
|
|
76
|
-
"no-var": "off",
|
|
77
66
|
"node/prefer-global/buffer": ["error", "always"],
|
|
78
67
|
"node/prefer-global/process": ["error", "always"],
|
|
79
68
|
"object-curly-newline": [
|
|
@@ -165,7 +154,6 @@ var eslint_config = antfu(
|
|
|
165
154
|
}
|
|
166
155
|
],
|
|
167
156
|
"perfectionist/sort-union-types": ["error", { type: "natural" }],
|
|
168
|
-
"prefer-regex-literals": "off",
|
|
169
157
|
"quotes": [
|
|
170
158
|
"error",
|
|
171
159
|
"single",
|
|
@@ -198,22 +186,6 @@ var eslint_config = antfu(
|
|
|
198
186
|
"saasmakers/vue-template-format-props": "error",
|
|
199
187
|
"saasmakers/vue-template-remove-comments": "error",
|
|
200
188
|
"saasmakers/vue-template-remove-true-attributes": "error",
|
|
201
|
-
"sort-imports": "off",
|
|
202
|
-
"ts/ban-ts-comment": "off",
|
|
203
|
-
"ts/ban-ts-ignore": "off",
|
|
204
|
-
"ts/ban-types": "off",
|
|
205
|
-
"ts/explicit-member-accessibility": "off",
|
|
206
|
-
"ts/no-explicit-any": "error",
|
|
207
|
-
"ts/no-invalid-this": "off",
|
|
208
|
-
"ts/no-namespace": "off",
|
|
209
|
-
"ts/no-require-imports": "off",
|
|
210
|
-
"ts/no-shadow": "off",
|
|
211
|
-
"ts/no-unused-expressions": "off",
|
|
212
|
-
"ts/no-use-before-define": "off",
|
|
213
|
-
"ts/no-var-requires": "off",
|
|
214
|
-
"ts/prefer-nullish-coalescing": "error",
|
|
215
|
-
"unicorn/filename-case": "off",
|
|
216
|
-
"vars-on-top": "off",
|
|
217
189
|
"vue/attributes-order": [
|
|
218
190
|
"error",
|
|
219
191
|
{
|
|
@@ -245,7 +217,6 @@ var eslint_config = antfu(
|
|
|
245
217
|
singleline: "beside"
|
|
246
218
|
}
|
|
247
219
|
],
|
|
248
|
-
// 'vue/define-macros-order': 'off',
|
|
249
220
|
"vue/max-attributes-per-line": [
|
|
250
221
|
"error",
|
|
251
222
|
{
|
|
@@ -261,7 +232,6 @@ var eslint_config = antfu(
|
|
|
261
232
|
ignoreWhenEmpty: true
|
|
262
233
|
}
|
|
263
234
|
],
|
|
264
|
-
"vue/no-side-effects-in-computed-properties": "off",
|
|
265
235
|
"vue/padding-line-between-tags": [
|
|
266
236
|
"error",
|
|
267
237
|
[
|
|
@@ -271,10 +241,7 @@ var eslint_config = antfu(
|
|
|
271
241
|
prev: "*"
|
|
272
242
|
}
|
|
273
243
|
]
|
|
274
|
-
]
|
|
275
|
-
"vue/return-in-computed-property": "off",
|
|
276
|
-
// This conflicts with another rule that removes empty `return` statements
|
|
277
|
-
"vue/singleline-html-element-content-newline": "off"
|
|
244
|
+
]
|
|
278
245
|
}
|
|
279
246
|
}
|
|
280
247
|
);
|
package/dist/eslint.config.d.ts
CHANGED
|
@@ -5,6 +5,10 @@ import storybook from 'eslint-plugin-storybook';
|
|
|
5
5
|
|
|
6
6
|
var eslint_config = antfu(
|
|
7
7
|
{
|
|
8
|
+
regexp: false,
|
|
9
|
+
typescript: true,
|
|
10
|
+
unocss: true,
|
|
11
|
+
vue: true,
|
|
8
12
|
ignores: [
|
|
9
13
|
"*.md",
|
|
10
14
|
"**/.nuxt",
|
|
@@ -16,11 +20,7 @@ var eslint_config = antfu(
|
|
|
16
20
|
"**/dumps/*.json",
|
|
17
21
|
"**/ios",
|
|
18
22
|
"node_modules"
|
|
19
|
-
]
|
|
20
|
-
regexp: false,
|
|
21
|
-
typescript: true,
|
|
22
|
-
unocss: true,
|
|
23
|
-
vue: true
|
|
23
|
+
]
|
|
24
24
|
},
|
|
25
25
|
{
|
|
26
26
|
languageOptions: {
|
|
@@ -62,18 +62,7 @@ var eslint_config = antfu(
|
|
|
62
62
|
min: 2
|
|
63
63
|
}
|
|
64
64
|
],
|
|
65
|
-
"no-console": "off",
|
|
66
|
-
"no-control-regex": "off",
|
|
67
|
-
"no-labels": "off",
|
|
68
|
-
"no-restricted-globals": "off",
|
|
69
|
-
// Fix
|
|
70
|
-
"no-restricted-syntax": "off",
|
|
71
|
-
"no-throw-literal": "off",
|
|
72
|
-
// Fix
|
|
73
|
-
"no-unmodified-loop-condition": "off",
|
|
74
|
-
// Fix
|
|
75
65
|
"no-use-before-define": "off",
|
|
76
|
-
"no-var": "off",
|
|
77
66
|
"node/prefer-global/buffer": ["error", "always"],
|
|
78
67
|
"node/prefer-global/process": ["error", "always"],
|
|
79
68
|
"object-curly-newline": [
|
|
@@ -165,7 +154,6 @@ var eslint_config = antfu(
|
|
|
165
154
|
}
|
|
166
155
|
],
|
|
167
156
|
"perfectionist/sort-union-types": ["error", { type: "natural" }],
|
|
168
|
-
"prefer-regex-literals": "off",
|
|
169
157
|
"quotes": [
|
|
170
158
|
"error",
|
|
171
159
|
"single",
|
|
@@ -198,22 +186,6 @@ var eslint_config = antfu(
|
|
|
198
186
|
"saasmakers/vue-template-format-props": "error",
|
|
199
187
|
"saasmakers/vue-template-remove-comments": "error",
|
|
200
188
|
"saasmakers/vue-template-remove-true-attributes": "error",
|
|
201
|
-
"sort-imports": "off",
|
|
202
|
-
"ts/ban-ts-comment": "off",
|
|
203
|
-
"ts/ban-ts-ignore": "off",
|
|
204
|
-
"ts/ban-types": "off",
|
|
205
|
-
"ts/explicit-member-accessibility": "off",
|
|
206
|
-
"ts/no-explicit-any": "error",
|
|
207
|
-
"ts/no-invalid-this": "off",
|
|
208
|
-
"ts/no-namespace": "off",
|
|
209
|
-
"ts/no-require-imports": "off",
|
|
210
|
-
"ts/no-shadow": "off",
|
|
211
|
-
"ts/no-unused-expressions": "off",
|
|
212
|
-
"ts/no-use-before-define": "off",
|
|
213
|
-
"ts/no-var-requires": "off",
|
|
214
|
-
"ts/prefer-nullish-coalescing": "error",
|
|
215
|
-
"unicorn/filename-case": "off",
|
|
216
|
-
"vars-on-top": "off",
|
|
217
189
|
"vue/attributes-order": [
|
|
218
190
|
"error",
|
|
219
191
|
{
|
|
@@ -245,7 +217,6 @@ var eslint_config = antfu(
|
|
|
245
217
|
singleline: "beside"
|
|
246
218
|
}
|
|
247
219
|
],
|
|
248
|
-
// 'vue/define-macros-order': 'off',
|
|
249
220
|
"vue/max-attributes-per-line": [
|
|
250
221
|
"error",
|
|
251
222
|
{
|
|
@@ -261,7 +232,6 @@ var eslint_config = antfu(
|
|
|
261
232
|
ignoreWhenEmpty: true
|
|
262
233
|
}
|
|
263
234
|
],
|
|
264
|
-
"vue/no-side-effects-in-computed-properties": "off",
|
|
265
235
|
"vue/padding-line-between-tags": [
|
|
266
236
|
"error",
|
|
267
237
|
[
|
|
@@ -271,10 +241,7 @@ var eslint_config = antfu(
|
|
|
271
241
|
prev: "*"
|
|
272
242
|
}
|
|
273
243
|
]
|
|
274
|
-
]
|
|
275
|
-
"vue/return-in-computed-property": "off",
|
|
276
|
-
// This conflicts with another rule that removes empty `return` statements
|
|
277
|
-
"vue/singleline-html-element-content-newline": "off"
|
|
244
|
+
]
|
|
278
245
|
}
|
|
279
246
|
}
|
|
280
247
|
);
|
package/dist/eslint.config.mjs
CHANGED
|
@@ -5,6 +5,10 @@ import storybook from 'eslint-plugin-storybook';
|
|
|
5
5
|
|
|
6
6
|
const eslint_config = antfu(
|
|
7
7
|
{
|
|
8
|
+
regexp: false,
|
|
9
|
+
typescript: true,
|
|
10
|
+
unocss: true,
|
|
11
|
+
vue: true,
|
|
8
12
|
ignores: [
|
|
9
13
|
"*.md",
|
|
10
14
|
"**/.nuxt",
|
|
@@ -16,11 +20,7 @@ const eslint_config = antfu(
|
|
|
16
20
|
"**/dumps/*.json",
|
|
17
21
|
"**/ios",
|
|
18
22
|
"node_modules"
|
|
19
|
-
]
|
|
20
|
-
regexp: false,
|
|
21
|
-
typescript: true,
|
|
22
|
-
unocss: true,
|
|
23
|
-
vue: true
|
|
23
|
+
]
|
|
24
24
|
},
|
|
25
25
|
{
|
|
26
26
|
languageOptions: {
|
|
@@ -62,18 +62,7 @@ const eslint_config = antfu(
|
|
|
62
62
|
min: 2
|
|
63
63
|
}
|
|
64
64
|
],
|
|
65
|
-
"no-console": "off",
|
|
66
|
-
"no-control-regex": "off",
|
|
67
|
-
"no-labels": "off",
|
|
68
|
-
"no-restricted-globals": "off",
|
|
69
|
-
// Fix
|
|
70
|
-
"no-restricted-syntax": "off",
|
|
71
|
-
"no-throw-literal": "off",
|
|
72
|
-
// Fix
|
|
73
|
-
"no-unmodified-loop-condition": "off",
|
|
74
|
-
// Fix
|
|
75
65
|
"no-use-before-define": "off",
|
|
76
|
-
"no-var": "off",
|
|
77
66
|
"node/prefer-global/buffer": ["error", "always"],
|
|
78
67
|
"node/prefer-global/process": ["error", "always"],
|
|
79
68
|
"object-curly-newline": [
|
|
@@ -165,7 +154,6 @@ const eslint_config = antfu(
|
|
|
165
154
|
}
|
|
166
155
|
],
|
|
167
156
|
"perfectionist/sort-union-types": ["error", { type: "natural" }],
|
|
168
|
-
"prefer-regex-literals": "off",
|
|
169
157
|
"quotes": [
|
|
170
158
|
"error",
|
|
171
159
|
"single",
|
|
@@ -198,22 +186,6 @@ const eslint_config = antfu(
|
|
|
198
186
|
"saasmakers/vue-template-format-props": "error",
|
|
199
187
|
"saasmakers/vue-template-remove-comments": "error",
|
|
200
188
|
"saasmakers/vue-template-remove-true-attributes": "error",
|
|
201
|
-
"sort-imports": "off",
|
|
202
|
-
"ts/ban-ts-comment": "off",
|
|
203
|
-
"ts/ban-ts-ignore": "off",
|
|
204
|
-
"ts/ban-types": "off",
|
|
205
|
-
"ts/explicit-member-accessibility": "off",
|
|
206
|
-
"ts/no-explicit-any": "error",
|
|
207
|
-
"ts/no-invalid-this": "off",
|
|
208
|
-
"ts/no-namespace": "off",
|
|
209
|
-
"ts/no-require-imports": "off",
|
|
210
|
-
"ts/no-shadow": "off",
|
|
211
|
-
"ts/no-unused-expressions": "off",
|
|
212
|
-
"ts/no-use-before-define": "off",
|
|
213
|
-
"ts/no-var-requires": "off",
|
|
214
|
-
"ts/prefer-nullish-coalescing": "error",
|
|
215
|
-
"unicorn/filename-case": "off",
|
|
216
|
-
"vars-on-top": "off",
|
|
217
189
|
"vue/attributes-order": [
|
|
218
190
|
"error",
|
|
219
191
|
{
|
|
@@ -245,7 +217,6 @@ const eslint_config = antfu(
|
|
|
245
217
|
singleline: "beside"
|
|
246
218
|
}
|
|
247
219
|
],
|
|
248
|
-
// 'vue/define-macros-order': 'off',
|
|
249
220
|
"vue/max-attributes-per-line": [
|
|
250
221
|
"error",
|
|
251
222
|
{
|
|
@@ -261,7 +232,6 @@ const eslint_config = antfu(
|
|
|
261
232
|
ignoreWhenEmpty: true
|
|
262
233
|
}
|
|
263
234
|
],
|
|
264
|
-
"vue/no-side-effects-in-computed-properties": "off",
|
|
265
235
|
"vue/padding-line-between-tags": [
|
|
266
236
|
"error",
|
|
267
237
|
[
|
|
@@ -271,10 +241,7 @@ const eslint_config = antfu(
|
|
|
271
241
|
prev: "*"
|
|
272
242
|
}
|
|
273
243
|
]
|
|
274
|
-
]
|
|
275
|
-
"vue/return-in-computed-property": "off",
|
|
276
|
-
// This conflicts with another rule that removes empty `return` statements
|
|
277
|
-
"vue/singleline-html-element-content-newline": "off"
|
|
244
|
+
]
|
|
278
245
|
}
|
|
279
246
|
}
|
|
280
247
|
);
|
package/dist/index.cjs
CHANGED
|
@@ -26,7 +26,7 @@ const rule$e = {
|
|
|
26
26
|
type: "layout"
|
|
27
27
|
},
|
|
28
28
|
create(context) {
|
|
29
|
-
const maxCharacters = context.options[0]?.maxCharacters
|
|
29
|
+
const maxCharacters = context.options[0]?.maxCharacters ?? 100;
|
|
30
30
|
return {
|
|
31
31
|
ConditionalExpression(node) {
|
|
32
32
|
if (node.type !== utils.AST_NODE_TYPES.ConditionalExpression) {
|
|
@@ -92,8 +92,8 @@ const rule$d = {
|
|
|
92
92
|
type: "layout"
|
|
93
93
|
},
|
|
94
94
|
create(context) {
|
|
95
|
-
const minItems = context.options[0]?.minItems
|
|
96
|
-
const maxLineLength = context.options[0]?.maxLineLength
|
|
95
|
+
const minItems = context.options[0]?.minItems ?? 5;
|
|
96
|
+
const maxLineLength = context.options[0]?.maxLineLength ?? 100;
|
|
97
97
|
function reportAndFix(node, messageId, fixFunction) {
|
|
98
98
|
context.report({
|
|
99
99
|
fix: fixFunction,
|
|
@@ -751,7 +751,7 @@ const rule$5 = {
|
|
|
751
751
|
fix: (fixer) => {
|
|
752
752
|
return fixer.removeRange(comment.range);
|
|
753
753
|
},
|
|
754
|
-
loc: comment.loc
|
|
754
|
+
loc: comment.loc ?? node.loc ?? {
|
|
755
755
|
end: {
|
|
756
756
|
column: 0,
|
|
757
757
|
line: 0
|
|
@@ -817,7 +817,7 @@ const rule$5 = {
|
|
|
817
817
|
const templateContent = templateMatch ? templateMatch[1] : "";
|
|
818
818
|
const scriptMatch = source.match(/<script[^>]*>([\s\S]*?)<\/script>/i);
|
|
819
819
|
const scriptContent = scriptMatch ? scriptMatch[1] : "";
|
|
820
|
-
const propDefinitions = propsText.match(/(\w+):\s*{([^}]+)}/g)
|
|
820
|
+
const propDefinitions = propsText.match(/(\w+):\s*{([^}]+)}/g) ?? [];
|
|
821
821
|
for (const propDef of propDefinitions) {
|
|
822
822
|
const propNameMatch = propDef.match(/^(\w+):\s*{([^}]+)}/);
|
|
823
823
|
if (!propNameMatch) {
|
|
@@ -1059,7 +1059,7 @@ const rule$1 = {
|
|
|
1059
1059
|
while (jsCommentMatch !== null) {
|
|
1060
1060
|
const fullMatch = jsCommentMatch[0];
|
|
1061
1061
|
const matchIndex = templateStartIndex + jsCommentMatch.index;
|
|
1062
|
-
const lineBeforeMatch = templateContent.substring(0, jsCommentMatch.index).split("\n").pop()
|
|
1062
|
+
const lineBeforeMatch = templateContent.substring(0, jsCommentMatch.index).split("\n").pop() ?? "";
|
|
1063
1063
|
const isInAttribute = lineBeforeMatch.includes('="') && !lineBeforeMatch.includes('"');
|
|
1064
1064
|
if (isInAttribute) {
|
|
1065
1065
|
jsCommentMatch = jsCommentRegex.exec(templateContent);
|
|
@@ -1117,7 +1117,7 @@ const rule = {
|
|
|
1117
1117
|
const fullMatch = trueAttributeMatch[0];
|
|
1118
1118
|
const attributeName = trueAttributeMatch[1];
|
|
1119
1119
|
const matchIndex = templateStartIndex + trueAttributeMatch.index;
|
|
1120
|
-
const lineBeforeMatch = templateContent.substring(0, trueAttributeMatch.index).split("\n").pop()
|
|
1120
|
+
const lineBeforeMatch = templateContent.substring(0, trueAttributeMatch.index).split("\n").pop() ?? "";
|
|
1121
1121
|
if (lineBeforeMatch.includes("{{") && !lineBeforeMatch.includes("}}")) {
|
|
1122
1122
|
trueAttributeMatch = trueAttributeRegex.exec(templateContent);
|
|
1123
1123
|
continue;
|
package/dist/index.mjs
CHANGED
|
@@ -22,7 +22,7 @@ const rule$e = {
|
|
|
22
22
|
type: "layout"
|
|
23
23
|
},
|
|
24
24
|
create(context) {
|
|
25
|
-
const maxCharacters = context.options[0]?.maxCharacters
|
|
25
|
+
const maxCharacters = context.options[0]?.maxCharacters ?? 100;
|
|
26
26
|
return {
|
|
27
27
|
ConditionalExpression(node) {
|
|
28
28
|
if (node.type !== AST_NODE_TYPES.ConditionalExpression) {
|
|
@@ -88,8 +88,8 @@ const rule$d = {
|
|
|
88
88
|
type: "layout"
|
|
89
89
|
},
|
|
90
90
|
create(context) {
|
|
91
|
-
const minItems = context.options[0]?.minItems
|
|
92
|
-
const maxLineLength = context.options[0]?.maxLineLength
|
|
91
|
+
const minItems = context.options[0]?.minItems ?? 5;
|
|
92
|
+
const maxLineLength = context.options[0]?.maxLineLength ?? 100;
|
|
93
93
|
function reportAndFix(node, messageId, fixFunction) {
|
|
94
94
|
context.report({
|
|
95
95
|
fix: fixFunction,
|
|
@@ -747,7 +747,7 @@ const rule$5 = {
|
|
|
747
747
|
fix: (fixer) => {
|
|
748
748
|
return fixer.removeRange(comment.range);
|
|
749
749
|
},
|
|
750
|
-
loc: comment.loc
|
|
750
|
+
loc: comment.loc ?? node.loc ?? {
|
|
751
751
|
end: {
|
|
752
752
|
column: 0,
|
|
753
753
|
line: 0
|
|
@@ -813,7 +813,7 @@ const rule$5 = {
|
|
|
813
813
|
const templateContent = templateMatch ? templateMatch[1] : "";
|
|
814
814
|
const scriptMatch = source.match(/<script[^>]*>([\s\S]*?)<\/script>/i);
|
|
815
815
|
const scriptContent = scriptMatch ? scriptMatch[1] : "";
|
|
816
|
-
const propDefinitions = propsText.match(/(\w+):\s*{([^}]+)}/g)
|
|
816
|
+
const propDefinitions = propsText.match(/(\w+):\s*{([^}]+)}/g) ?? [];
|
|
817
817
|
for (const propDef of propDefinitions) {
|
|
818
818
|
const propNameMatch = propDef.match(/^(\w+):\s*{([^}]+)}/);
|
|
819
819
|
if (!propNameMatch) {
|
|
@@ -1055,7 +1055,7 @@ const rule$1 = {
|
|
|
1055
1055
|
while (jsCommentMatch !== null) {
|
|
1056
1056
|
const fullMatch = jsCommentMatch[0];
|
|
1057
1057
|
const matchIndex = templateStartIndex + jsCommentMatch.index;
|
|
1058
|
-
const lineBeforeMatch = templateContent.substring(0, jsCommentMatch.index).split("\n").pop()
|
|
1058
|
+
const lineBeforeMatch = templateContent.substring(0, jsCommentMatch.index).split("\n").pop() ?? "";
|
|
1059
1059
|
const isInAttribute = lineBeforeMatch.includes('="') && !lineBeforeMatch.includes('"');
|
|
1060
1060
|
if (isInAttribute) {
|
|
1061
1061
|
jsCommentMatch = jsCommentRegex.exec(templateContent);
|
|
@@ -1113,7 +1113,7 @@ const rule = {
|
|
|
1113
1113
|
const fullMatch = trueAttributeMatch[0];
|
|
1114
1114
|
const attributeName = trueAttributeMatch[1];
|
|
1115
1115
|
const matchIndex = templateStartIndex + trueAttributeMatch.index;
|
|
1116
|
-
const lineBeforeMatch = templateContent.substring(0, trueAttributeMatch.index).split("\n").pop()
|
|
1116
|
+
const lineBeforeMatch = templateContent.substring(0, trueAttributeMatch.index).split("\n").pop() ?? "";
|
|
1117
1117
|
if (lineBeforeMatch.includes("{{") && !lineBeforeMatch.includes("}}")) {
|
|
1118
1118
|
trueAttributeMatch = trueAttributeRegex.exec(templateContent);
|
|
1119
1119
|
continue;
|