Skip to content

Commit 776cef3

Browse files
authored
Merge branch 'master' into test/strict/func-call-spacing
2 parents 8a4b4a2 + d2b201a commit 776cef3

24 files changed

+1653
-398
lines changed

docs/rules/match-component-import-name.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ since: v8.7.0
1212
1313
## :book: Rule Details
1414

15-
By default, this rule will validate that the imported name matches the name of the components object property identifer. Note that "matches" means that the imported name matches either the PascalCase or kebab-case version of the components object property identifer. If you would like to enforce that it must match only one of PascalCase or kebab-case, use this rule in conjunction with the rule [vue/component-definition-name-casing](./component-definition-name-casing.md).
15+
By default, this rule will validate that the imported name matches the name of the components object property identifier. Note that "matches" means that the imported name matches either the PascalCase or kebab-case version of the components object property identifier. If you would like to enforce that it must match only one of PascalCase or kebab-case, use this rule in conjunction with the rule [vue/component-definition-name-casing](./component-definition-name-casing.md).
1616

1717
<eslint-code-block :rules="{'vue/match-component-import-name': ['error']}">
1818

docs/rules/require-explicit-slots.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ since: v9.21.0
1212
1313
## :book: Rule Details
1414

15-
This rule enforces all slots used in the template to be defined once either in the `script setup` block with the [`defineSlots`](https://vuejs.org/api/sfc-script-setup.html#defineslots) macro, or with the [`slots property`](https://vuejs.org/api/options-rendering.html#slots) in the Options API.
15+
This rule enforces all slots used in the template to be defined once either in the `script setup` block with the [`defineSlots` macro](https://vuejs.org/api/sfc-script-setup.html#defineslots), or with the [`slots` property](https://vuejs.org/api/options-rendering.html#slots) in the Options API.
1616

1717
<eslint-code-block :rules="{'vue/require-explicit-slots': ['error']}">
1818

tests/lib/rules/html-closing-bracket-spacing.js

Lines changed: 44 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -50,19 +50,22 @@ ruleTester.run('html-closing-bracket-spacing', rule, {
5050
message: "Expected no space before '>', but found.",
5151
line: 2,
5252
column: 7,
53-
endColumn: 9
53+
endColumn: 9,
54+
endLine: 2
5455
},
5556
{
5657
message: "Expected no space before '>', but found.",
5758
line: 3,
5859
column: 8,
59-
endColumn: 10
60+
endColumn: 10,
61+
endLine: 3
6062
},
6163
{
6264
message: "Expected a space before '/>', but not found.",
6365
line: 4,
6466
column: 7,
65-
endColumn: 9
67+
endColumn: 9,
68+
endLine: 4
6669
}
6770
]
6871
},
@@ -74,13 +77,15 @@ ruleTester.run('html-closing-bracket-spacing', rule, {
7477
message: "Expected no space before '>', but found.",
7578
line: 2,
7679
column: 11,
77-
endColumn: 13
80+
endColumn: 13,
81+
endLine: 2
7882
},
7983
{
8084
message: "Expected a space before '/>', but not found.",
8185
line: 3,
8286
column: 11,
83-
endColumn: 13
87+
endColumn: 13,
88+
endLine: 3
8489
}
8590
]
8691
},
@@ -93,13 +98,15 @@ ruleTester.run('html-closing-bracket-spacing', rule, {
9398
message: "Expected no space before '>', but found.",
9499
line: 2,
95100
column: 15,
96-
endColumn: 17
101+
endColumn: 17,
102+
endLine: 2
97103
},
98104
{
99105
message: "Expected a space before '/>', but not found.",
100106
line: 3,
101107
column: 15,
102-
endColumn: 17
108+
endColumn: 17,
109+
endLine: 3
103110
}
104111
]
105112
},
@@ -119,37 +126,43 @@ ruleTester.run('html-closing-bracket-spacing', rule, {
119126
message: "Expected no space before '>', but found.",
120127
line: 2,
121128
column: 18,
122-
endColumn: 20
129+
endColumn: 20,
130+
endLine: 2
123131
},
124132
{
125133
message: "Expected no space before '>', but found.",
126134
line: 2,
127135
column: 30,
128-
endColumn: 32
136+
endColumn: 32,
137+
endLine: 2
129138
},
130139
{
131140
message: "Expected no space before '>', but found.",
132141
line: 3,
133142
column: 16,
134-
endColumn: 18
143+
endColumn: 18,
144+
endLine: 3
135145
},
136146
{
137147
message: "Expected no space before '>', but found.",
138148
line: 3,
139149
column: 26,
140-
endColumn: 28
150+
endColumn: 28,
151+
endLine: 3
141152
},
142153
{
143154
message: "Expected no space before '>', but found.",
144155
line: 4,
145156
column: 15,
146-
endColumn: 17
157+
endColumn: 17,
158+
endLine: 4
147159
},
148160
{
149161
message: "Expected no space before '>', but found.",
150162
line: 4,
151163
column: 24,
152-
endColumn: 26
164+
endColumn: 26,
165+
endLine: 4
153166
}
154167
]
155168
},
@@ -168,19 +181,22 @@ ruleTester.run('html-closing-bracket-spacing', rule, {
168181
message: "Expected a space before '>', but not found.",
169182
line: 2,
170183
column: 7,
171-
endColumn: 8
184+
endColumn: 8,
185+
endLine: 2
172186
},
173187
{
174188
message: "Expected a space before '>', but not found.",
175189
line: 3,
176190
column: 8,
177-
endColumn: 9
191+
endColumn: 9,
192+
endLine: 3
178193
},
179194
{
180195
message: "Expected no space before '/>', but found.",
181196
line: 4,
182197
column: 7,
183-
endColumn: 10
198+
endColumn: 10,
199+
endLine: 4
184200
}
185201
]
186202
},
@@ -207,37 +223,43 @@ ruleTester.run('html-closing-bracket-spacing', rule, {
207223
message: "Expected a space before '>', but not found.",
208224
line: 2,
209225
column: 18,
210-
endColumn: 19
226+
endColumn: 19,
227+
endLine: 2
211228
},
212229
{
213230
message: "Expected a space before '>', but not found.",
214231
line: 2,
215232
column: 29,
216-
endColumn: 30
233+
endColumn: 30,
234+
endLine: 2
217235
},
218236
{
219237
message: "Expected a space before '>', but not found.",
220238
line: 3,
221239
column: 16,
222-
endColumn: 17
240+
endColumn: 17,
241+
endLine: 3
223242
},
224243
{
225244
message: "Expected a space before '>', but not found.",
226245
line: 3,
227246
column: 25,
228-
endColumn: 26
247+
endColumn: 26,
248+
endLine: 3
229249
},
230250
{
231251
message: "Expected a space before '>', but not found.",
232252
line: 4,
233253
column: 15,
234-
endColumn: 16
254+
endColumn: 16,
255+
endLine: 4
235256
},
236257
{
237258
message: "Expected a space before '>', but not found.",
238259
line: 4,
239260
column: 23,
240-
endColumn: 24
261+
endColumn: 24,
262+
endLine: 4
241263
}
242264
]
243265
}

tests/lib/rules/html-comment-content-newline.js

Lines changed: 78 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -264,13 +264,15 @@ tester.run('html-comment-content-newline', rule, {
264264
message: "Expected line break after '<!--'.",
265265
line: 6,
266266
column: 15,
267-
endColumn: 16
267+
endColumn: 16,
268+
endLine: 6
268269
},
269270
{
270271
message: "Expected line break before '-->'.",
271272
line: 7,
272273
column: 20,
273-
endColumn: 21
274+
endColumn: 21,
275+
endLine: 7
274276
}
275277
]
276278
},
@@ -293,25 +295,29 @@ tester.run('html-comment-content-newline', rule, {
293295
message: "Expected line break after '<!--'.",
294296
line: 3,
295297
column: 15,
296-
endColumn: 15
298+
endColumn: 15,
299+
endLine: 3
297300
},
298301
{
299302
message: "Expected line break before '-->'.",
300303
line: 3,
301304
column: 22,
302-
endColumn: 22
305+
endColumn: 22,
306+
endLine: 3
303307
},
304308
{
305309
message: "Expected line break after '<!--'.",
306310
line: 4,
307311
column: 15,
308-
endColumn: 17
312+
endColumn: 17,
313+
endLine: 4
309314
},
310315
{
311316
message: "Expected line break before '-->'.",
312317
line: 4,
313318
column: 24,
314-
endColumn: 26
319+
endColumn: 26,
320+
endLine: 4
315321
}
316322
]
317323
},
@@ -363,13 +369,15 @@ comment
363369
message: "Expected line break after '<!--'.",
364370
line: 3,
365371
column: 15,
366-
endColumn: 23
372+
endColumn: 23,
373+
endLine: 3
367374
},
368375
{
369376
message: "Expected line break before '-->'.",
370377
line: 3,
371378
column: 30,
372-
endColumn: 38
379+
endColumn: 38,
380+
endLine: 3
373381
}
374382
]
375383
},
@@ -383,8 +391,20 @@ comment
383391
output: null,
384392
options: ['always', { exceptions: ['+'] }],
385393
errors: [
386-
'Expected line break after exception block.',
387-
'Expected line break before exception block.'
394+
{
395+
message: 'Expected line break after exception block.',
396+
line: 3,
397+
column: 31,
398+
endLine: 3,
399+
endColumn: 31
400+
},
401+
{
402+
message: 'Expected line break before exception block.',
403+
line: 3,
404+
column: 38,
405+
endLine: 3,
406+
endColumn: 38
407+
}
388408
]
389409
},
390410
{
@@ -396,8 +416,20 @@ comment
396416
output: null,
397417
options: ['always', { exceptions: ['*'] }],
398418
errors: [
399-
'Expected line break after exception block.',
400-
'Expected line break before exception block.'
419+
{
420+
message: 'Expected line break after exception block.',
421+
line: 3,
422+
column: 20,
423+
endLine: 3,
424+
endColumn: 20
425+
},
426+
{
427+
message: 'Expected line break before exception block.',
428+
line: 3,
429+
column: 27,
430+
endLine: 3,
431+
endColumn: 27
432+
}
401433
]
402434
},
403435
{
@@ -413,8 +445,20 @@ comment
413445
`,
414446
options: ['always', { exceptions: ['#+#-'] }],
415447
errors: [
416-
'Expected line break after exception block.',
417-
"Expected line break before '-->'."
448+
{
449+
message: 'Expected line break after exception block.',
450+
line: 3,
451+
column: 27,
452+
endLine: 3,
453+
endColumn: 27
454+
},
455+
{
456+
message: "Expected line break before '-->'.",
457+
line: 3,
458+
column: 38,
459+
endLine: 3,
460+
endColumn: 38
461+
}
418462
]
419463
},
420464
{
@@ -426,11 +470,19 @@ comment
426470
output: null,
427471
options: ['always', { exceptions: ['*', '++'] }],
428472
errors: [
429-
'Expected line break after exception block.',
473+
{
474+
message: 'Expected line break after exception block.',
475+
line: 3,
476+
column: 20,
477+
endLine: 3,
478+
endColumn: 20
479+
},
430480
{
431481
message: 'Expected line break before exception block.',
432482
line: 3,
433-
column: 27
483+
column: 27,
484+
endLine: 3,
485+
endColumn: 27
434486
}
435487
]
436488
},
@@ -443,11 +495,19 @@ comment
443495
output: null,
444496
options: ['always', { exceptions: ['*', '++'] }],
445497
errors: [
446-
'Expected line break after exception block.',
498+
{
499+
message: 'Expected line break after exception block.',
500+
line: 3,
501+
column: 20,
502+
endLine: 3,
503+
endColumn: 20
504+
},
447505
{
448506
message: 'Expected line break before exception block.',
449507
line: 3,
450-
column: 28
508+
column: 28,
509+
endLine: 3,
510+
endColumn: 28
451511
}
452512
]
453513
}

0 commit comments

Comments
 (0)