Skip to content

Commit 17f4be2

Browse files
authored
docs: Fix examples in no-multiple-empty-lines rule (#16835)
* docs: Fix examples in no-multiple-empty-lines rule * chore: Add missing `::: correct` and `::: incorrect`
1 parent 9c7cfe3 commit 17f4be2

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

docs/src/rules/no-multiple-empty-lines.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ Examples of **incorrect** code for this rule with the default `{ "max": 2 }` opt
3131
var foo = 5;
3232

3333

34+
3435
var bar = 3;
3536
```
3637

@@ -45,6 +46,7 @@ Examples of **correct** code for this rule with the default `{ "max": 2 }` optio
4546

4647
var foo = 5;
4748

49+
4850
var bar = 3;
4951
```
5052

@@ -61,8 +63,10 @@ Examples of **incorrect** code for this rule with the `{ max: 2, maxEOF: 0 }` op
6163

6264
var foo = 5;
6365

66+
6467
var bar = 3;
6568

69+
6670
```
6771

6872
:::
@@ -76,6 +80,7 @@ Examples of **correct** code for this rule with the `{ max: 2, maxEOF: 0 }` opti
7680

7781
var foo = 5;
7882

83+
7984
var bar = 3;
8085
```
8186

@@ -85,6 +90,8 @@ var bar = 3;
8590

8691
**Incorrect**:
8792

93+
::: incorrect
94+
8895
```js
8996
1 /*eslint no-multiple-empty-lines: ["error", { "max": 2, "maxEOF": 0 }]*/
9097
2
@@ -96,8 +103,12 @@ var bar = 3;
96103
8
97104
```
98105

106+
:::
107+
99108
**Correct**:
100109

110+
::: correct
111+
101112
```js
102113
1 /*eslint no-multiple-empty-lines: ["error", { "max": 2, "maxEOF": 0 }]*/
103114
2
@@ -108,6 +119,8 @@ var bar = 3;
108119
7
109120
```
110121

122+
:::
123+
111124
### maxBOF
112125

113126
Examples of **incorrect** code for this rule with the `{ max: 2, maxBOF: 1 }` options:
@@ -117,8 +130,10 @@ Examples of **incorrect** code for this rule with the `{ max: 2, maxBOF: 1 }` op
117130
```js
118131
/*eslint no-multiple-empty-lines: ["error", { "max": 2, "maxBOF": 1 }]*/
119132

133+
120134
var foo = 5;
121135

136+
122137
var bar = 3;
123138
```
124139

@@ -133,6 +148,7 @@ Examples of **correct** code for this rule with the `{ max: 2, maxBOF: 1 }` opti
133148

134149
var foo = 5;
135150

151+
136152
var bar = 3;
137153
```
138154

0 commit comments

Comments
 (0)