Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs: Clean up sort-var #7045

Merged
merged 1 commit into from Sep 3, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 6 additions & 8 deletions docs/rules/sort-vars.md
Expand Up @@ -7,7 +7,7 @@ When declaring multiple variables within the same block, some developers prefer
This rule checks all variable declaration blocks and verifies that all variables are sorted alphabetically.
The default configuration of the rule is case-sensitive.

The following patterns are considered problems:
Examples of **incorrect** code for this rule:

```js
/*eslint sort-vars: "error"*/
Expand All @@ -19,7 +19,7 @@ var a, B, c;
var a, A;
```

The following patterns are not considered problems:
Examples of **correct** code for this rule:

```js
/*eslint sort-vars: "error"*/
Expand Down Expand Up @@ -52,15 +52,13 @@ var c, d, a, e;

## Options

```
"sort-vars": [<enabled>, { "ignoreCase": <boolean> }]
```
This rule has an object option:

### `ignoreCase`
* `"ignoreCase": true` (default `false`) ignores the case-sensitivity of the variables order

When `true` the rule ignores the case-sensitivity of the variables order.
### ignoreCase

The following patterns are not considered problems:
Examples of **correct** code for this rule with the `{ "ignoreCase": true }` option:

```js
/*eslint sort-vars: ["error", { "ignoreCase": true }]*/
Expand Down