Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 10 additions & 9 deletions docs/src/rules/no-trailing-spaces.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ Examples of **incorrect** code for this rule:
```js
/*eslint no-trailing-spaces: "error"*/

var foo = 0;//•••••
var baz = 5;//••
//•••••
var foo = 0;/* trailing whitespace */
var baz = 5;/* trailing whitespace */
/* trailing whitespace */
```

:::
Expand Down Expand Up @@ -58,7 +58,8 @@ Examples of **correct** code for this rule with the `{ "skipBlankLines": true }`

var foo = 0;
var baz = 5;
//•••••
// ↓ a line with whitespace only ↓

```

:::
Expand All @@ -72,12 +73,12 @@ Examples of **correct** code for this rule with the `{ "ignoreComments": true }`
```js
/*eslint no-trailing-spaces: ["error", { "ignoreComments": true }]*/

//foo•
//•••••
// ↓ these comments have trailing whitespace →
//
/**
*baz
*••
*bar
* baz
*
* bar
*/
```

Expand Down