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

chore: add version to rules #16022

Closed
Closed
Show file tree
Hide file tree
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
4 changes: 4 additions & 0 deletions docs/src/rules/accessor-pairs.md
Original file line number Diff line number Diff line change
Expand Up @@ -294,3 +294,7 @@ See [no-dupe-class-members](no-dupe-class-members) if you also want to disallow
## When Not To Use It

You can turn this rule off if you are not concerned with the simultaneous presence of setters and getters on objects.

## Version

This rule was introduced in ESLint 0.22.0.
4 changes: 4 additions & 0 deletions docs/src/rules/array-bracket-newline.md
Original file line number Diff line number Diff line change
Expand Up @@ -285,3 +285,7 @@ If you don't want to enforce line breaks after opening and before closing array
## Compatibility

* **JSCS:** [validateNewlineAfterArrayElements](https://jscs-dev.github.io/rule/validateNewlineAfterArrayElements)

## Version

This rule was introduced in ESLint 4.0.0-alpha.1.
4 changes: 4 additions & 0 deletions docs/src/rules/array-bracket-spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -228,3 +228,7 @@ var arr = [[ 1, 2 ], 2, [ 3, 4 ]];
## When Not To Use It

You can turn this rule off if you are not concerned with the consistency of spacing between array brackets.

## Version

This rule was introduced in ESLint 0.24.0.
4 changes: 4 additions & 0 deletions docs/src/rules/array-callback-return.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,3 +158,7 @@ This rule checks callback functions of methods with the given names, *even if* t
## When Not To Use It

If you don't want to warn about usage of `return` statement in callbacks of array's methods, then it's safe to disable this rule.

## Version

This rule was introduced in ESLint 2.0.0-alpha-1.
4 changes: 4 additions & 0 deletions docs/src/rules/array-element-newline.md
Original file line number Diff line number Diff line change
Expand Up @@ -395,3 +395,7 @@ If you don't want to enforce linebreaks between array elements, don't enable thi
## Compatibility

* **JSCS:** [validateNewlineAfterArrayElements](https://jscs-dev.github.io/rule/validateNewlineAfterArrayElements)

## Version

This rule was introduced in ESLint 4.0.0-rc.0.
4 changes: 4 additions & 0 deletions docs/src/rules/arrow-body-style.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,3 +147,7 @@ Examples of **correct** code for this rule with the `"never"` option:
let foo = () => 0;
let foo = () => ({ foo: 0 });
```

## Version

This rule was introduced in ESLint 1.8.0.
4 changes: 4 additions & 0 deletions docs/src/rules/arrow-parens.md
Original file line number Diff line number Diff line change
Expand Up @@ -232,3 +232,7 @@ a((foo) => { if (true) {} });
([a, b]) => a;
({a, b}) => a;
```

## Version

This rule was introduced in ESLint 1.0.0-rc-1.
4 changes: 4 additions & 0 deletions docs/src/rules/arrow-spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,3 +100,7 @@ Examples of **correct** code for this rule with the `{ "before": false, "after":
(a)=> {};
()=> {'\n'};
```

## Version

This rule was introduced in ESLint 1.0.0-rc-1.
4 changes: 4 additions & 0 deletions docs/src/rules/block-scoped-var.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,3 +114,7 @@ class C {
}
}
```

## Version

This rule was introduced in ESLint 0.1.0.
4 changes: 4 additions & 0 deletions docs/src/rules/block-spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,3 +85,7 @@ class C {
## When Not To Use It

If you don't want to be notified about spacing style inside of blocks, you can safely disable this rule.

## Version

This rule was introduced in ESLint 1.2.0.
4 changes: 4 additions & 0 deletions docs/src/rules/brace-style.md
Original file line number Diff line number Diff line change
Expand Up @@ -397,3 +397,7 @@ class D { static { foo(); } }
## When Not To Use It

If you don't want to enforce a particular brace style, don't enable this rule.

## Version

This rule was introduced in ESLint 0.0.7.
4 changes: 4 additions & 0 deletions docs/src/rules/callback-return.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,3 +176,7 @@ function foo(err, callback) {
There are some cases where you might want to call a callback function more than once. In those cases this rule
may lead to incorrect behavior. In those cases you may want to reserve a special name for those callbacks and
not include that in the list of callbacks that trigger warnings.

## Version

This rule was introduced in ESLint 1.0.0-rc-1.
4 changes: 4 additions & 0 deletions docs/src/rules/camelcase.md
Original file line number Diff line number Diff line change
Expand Up @@ -275,3 +275,7 @@ function UNSAFE_componentWillMount() {
## When Not To Use It

If you have established coding standards using a different naming convention (separating words with underscores), turn this rule off.

## Version

This rule was introduced in ESLint 0.0.2.
4 changes: 4 additions & 0 deletions docs/src/rules/capitalized-comments.md
Original file line number Diff line number Diff line change
Expand Up @@ -256,3 +256,7 @@ This rule can be disabled if you do not care about the grammatical style of comm

* **JSCS**: [requireCapitalizedComments](https://jscs-dev.github.io/rule/requireCapitalizedComments)
* **JSCS**: [disallowCapitalizedComments](https://jscs-dev.github.io/rule/disallowCapitalizedComments)

## Version

This rule was introduced in ESLint 3.11.0.
4 changes: 4 additions & 0 deletions docs/src/rules/class-methods-use-this.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,3 +176,7 @@ class A {
foo = () => {}
}
```

## Version

This rule was introduced in ESLint 3.4.0.
4 changes: 4 additions & 0 deletions docs/src/rules/comma-dangle.md
Original file line number Diff line number Diff line change
Expand Up @@ -322,3 +322,7 @@ new foo(a, b,);
## When Not To Use It

You can turn this rule off if you are not concerned with dangling commas.

## Version

This rule was introduced in ESLint 0.16.0.
4 changes: 4 additions & 0 deletions docs/src/rules/comma-spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,3 +130,7 @@ var arr = [,2 ,3]
## When Not To Use It

If your project will not be following a consistent comma-spacing pattern, turn this rule off.

## Version

This rule was introduced in ESLint 0.9.0.
4 changes: 4 additions & 0 deletions docs/src/rules/comma-style.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,3 +169,7 @@ var o = {fst:1,
## When Not To Use It

This rule can safely be turned off if your project does not care about enforcing a consistent comma style.

## Version

This rule was introduced in ESLint 0.9.0.
4 changes: 4 additions & 0 deletions docs/src/rules/complexity.md
Original file line number Diff line number Diff line change
Expand Up @@ -144,3 +144,7 @@ is equivalent to
## When Not To Use It

If you can't determine an appropriate complexity limit for your code, then it's best to disable this rule.

## Version

This rule was introduced in ESLint 0.0.9.
4 changes: 4 additions & 0 deletions docs/src/rules/computed-property-spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,3 +184,7 @@ const Bar = class {
## When Not To Use It

You can turn this rule off if you are not concerned with the consistency of computed properties.

## Version

This rule was introduced in ESLint 0.23.0.
4 changes: 4 additions & 0 deletions docs/src/rules/consistent-return.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,3 +150,7 @@ function bar(condition) {
## When Not To Use It

If you want to allow functions to have different `return` behavior depending on code branching, then it is safe to disable this rule.

## Version

This rule was introduced in ESLint 0.4.0.
4 changes: 4 additions & 0 deletions docs/src/rules/consistent-this.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,3 +89,7 @@ that = this;
## When Not To Use It

If you need to capture nested context, `consistent-this` is going to be problematic. Code of that nature is usually difficult to read and maintain and you should consider refactoring it.

## Version

This rule was introduced in ESLint 0.0.9.
4 changes: 4 additions & 0 deletions docs/src/rules/constructor-super.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,3 +67,7 @@ class A extends B {
## When Not To Use It

If you don't want to be notified about invalid/missing `super()` callings in constructors, you can safely disable this rule.

## Version

This rule was introduced in ESLint 0.24.0.
4 changes: 4 additions & 0 deletions docs/src/rules/curly.md
Original file line number Diff line number Diff line change
Expand Up @@ -308,3 +308,7 @@ if (foo)
## When Not To Use It

If you have no strict conventions about when to use block statements and when not to, you can safely disable this rule.

## Version

This rule was introduced in ESLint 0.0.2.
4 changes: 4 additions & 0 deletions docs/src/rules/default-case-last.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,3 +126,7 @@ if (foo !== 0) {
}
doSomethingAnyway();
```

## Version

This rule was introduced in ESLint 7.0.0-alpha.0.
4 changes: 4 additions & 0 deletions docs/src/rules/default-case.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,3 +128,7 @@ switch(a) {
## When Not To Use It

If you don't want to enforce a `default` case for `switch` statements, you can safely disable this rule.

## Version

This rule was introduced in ESLint 0.6.0.
4 changes: 4 additions & 0 deletions docs/src/rules/default-param-last.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,7 @@ Examples of **correct** code for this rule:

function f(a, b = 0) {}
```

## Version

This rule was introduced in ESLint 6.4.0.
4 changes: 4 additions & 0 deletions docs/src/rules/dot-location.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,3 +90,7 @@ var bar = object.property;
## When Not To Use It

You can turn this rule off if you are not concerned with the consistency of newlines before or after dots in member expressions.

## Version

This rule was introduced in ESLint 0.21.0.
4 changes: 4 additions & 0 deletions docs/src/rules/dot-notation.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,3 +87,7 @@ data["fooBar"] = 42;
var data = {};
data["foo_bar"] = 42; // no warning
```

## Version

This rule was introduced in ESLint 0.0.7.
4 changes: 4 additions & 0 deletions docs/src/rules/eol-last.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,7 @@ This rule has a string option:
* `"windows"` (deprecated) is identical to "always", but will use a CRLF character when autofixing

**Deprecated:** The options `"unix"` and `"windows"` are deprecated. If you need to enforce a specific linebreak style, use this rule in conjunction with `linebreak-style`.

## Version

This rule was introduced in ESLint 0.7.1.
4 changes: 4 additions & 0 deletions docs/src/rules/eqeqeq.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,3 +132,7 @@ foo == null
## When Not To Use It

If you don't want to enforce a style for using equality operators, then it's safe to disable this rule.

## Version

This rule was introduced in ESLint 0.0.2.
4 changes: 4 additions & 0 deletions docs/src/rules/for-direction.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,7 @@ Examples of **correct** code for this rule:
for (var i = 0; i < 10; i++) {
}
```

## Version

This rule was introduced in ESLint 4.0.0-beta.0.
4 changes: 4 additions & 0 deletions docs/src/rules/func-call-spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,3 +110,7 @@ This rule can safely be turned off if your project does not care about enforcing

* **JSCS**: [disallowSpacesInCallExpression](https://jscs-dev.github.io/rule/disallowSpacesInCallExpression)
* **JSCS**: [requireSpacesInCallExpression](https://jscs-dev.github.io/rule/requireSpacesInCallExpression)

## Version

This rule was introduced in ESLint 3.3.0.
4 changes: 4 additions & 0 deletions docs/src/rules/func-name-matching.md
Original file line number Diff line number Diff line change
Expand Up @@ -183,3 +183,7 @@ Do not use this rule if you want to allow named functions to have different name
## Compatibility

* **JSCS**: [requireMatchingFunctionName](https://jscs-dev.github.io/rule/requireMatchingFunctionName)

## Version

This rule was introduced in ESLint 3.8.0.
4 changes: 4 additions & 0 deletions docs/src/rules/func-names.md
Original file line number Diff line number Diff line change
Expand Up @@ -220,3 +220,7 @@ var foo = bar(function *baz() {});

* **JSCS**: [requireAnonymousFunctions](https://jscs-dev.github.io/rule/requireAnonymousFunctions)
* **JSCS**: [disallowAnonymousFunctions](https://jscs-dev.github.io/rule/disallowAnonymousFunctions)

## Version

This rule was introduced in ESLint 0.4.0.
4 changes: 4 additions & 0 deletions docs/src/rules/func-style.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,3 +134,7 @@ var foo = () => {};
## When Not To Use It

If you want to allow developers to each decide how they want to write functions on their own, then you can disable this rule.

## Version

This rule was introduced in ESLint 0.2.0.
4 changes: 4 additions & 0 deletions docs/src/rules/function-call-argument-newline.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,3 +204,7 @@ baz(
## When Not To Use It

If you don't want to enforce line breaks between arguments, don't enable this rule.

## Version

This rule was introduced in ESLint 6.2.0.
4 changes: 4 additions & 0 deletions docs/src/rules/function-paren-newline.md
Original file line number Diff line number Diff line change
Expand Up @@ -335,3 +335,7 @@ foo(
## When Not To Use It

If don't want to enforce consistent linebreaks inside function parentheses, do not turn on this rule.

## Version

This rule was introduced in ESLint 4.6.0.
4 changes: 4 additions & 0 deletions docs/src/rules/generator-star-spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -212,3 +212,7 @@ class Class { static * method() {} }
## When Not To Use It

If your project will not be using generators or you are not concerned with spacing consistency, you do not need this rule.

## Version

This rule was introduced in ESLint 0.17.0.
4 changes: 4 additions & 0 deletions docs/src/rules/getter-return.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,3 +102,7 @@ p = {
## When Not To Use It

If your project will not be using ES5 property getters you do not need this rule.

## Version

This rule was introduced in ESLint 4.2.0.
4 changes: 4 additions & 0 deletions docs/src/rules/global-require.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,3 +103,7 @@ var x = require("x"),
## When Not To Use It

If you have a module that must be initialized with information that comes from the file-system or if a module is only used in very rare situations and will cause significant overhead to load it may make sense to disable the rule. If you need to `require()` an optional dependency inside of a `try`/`catch`, you can disable this rule for just that dependency using the `// eslint-disable-line global-require` comment.

## Version

This rule was introduced in ESLint 1.4.0.
4 changes: 4 additions & 0 deletions docs/src/rules/grouped-accessor-pairs.md
Original file line number Diff line number Diff line change
Expand Up @@ -327,3 +327,7 @@ Also, this rule does not report any warnings for properties that have duplicate
See [no-dupe-keys](no-dupe-keys) if you also want to disallow duplicate keys in object literals.

See [no-dupe-class-members](no-dupe-class-members) if you also want to disallow duplicate names in class definitions.

## Version

This rule was introduced in ESLint 6.7.0.
4 changes: 4 additions & 0 deletions docs/src/rules/guard-for-in.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,7 @@ for (key in foo) {
}
}
```

## Version

This rule was introduced in ESLint 0.0.6.
4 changes: 4 additions & 0 deletions docs/src/rules/handle-callback-err.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,3 +86,7 @@ If the configured name of the error variable begins with a `^` it is considered

There are cases where it may be safe for your application to ignore errors, however only ignore errors if you are
confident that some other form of monitoring will help you catch the problem.

## Version

This rule was introduced in ESLint 0.4.5.
4 changes: 4 additions & 0 deletions docs/src/rules/id-blacklist.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@ rule_type: suggestion
Disallows specified identifiers.

This rule was **deprecated** in ESLint v7.5.0 and replaced by the [id-denylist](id-denylist) rule.

## Version

This rule was introduced in ESLint 2.0.0-beta.2.
4 changes: 4 additions & 0 deletions docs/src/rules/id-denylist.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,3 +121,7 @@ class Foo {
## When Not To Use It

You can turn this rule off if you do not want to restrict the use of certain identifiers.

## Version

This rule was introduced in ESLint 7.4.0.
4 changes: 4 additions & 0 deletions docs/src/rules/id-length.md
Original file line number Diff line number Diff line change
Expand Up @@ -258,3 +258,7 @@ var [E] = arr;
const { y } = foo;
const { a: z } = foo;
```

## Version

This rule was introduced in ESLint 1.0.0.
4 changes: 4 additions & 0 deletions docs/src/rules/id-match.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,3 +176,7 @@ var { category_id: category_id } = query;
## When Not To Use It

If you don't want to enforce any particular naming convention for all identifiers, or your naming convention is too complex to be enforced by configuring this rule, then you should not enable this rule.

## Version

This rule was introduced in ESLint 1.0.0.
4 changes: 4 additions & 0 deletions docs/src/rules/implicit-arrow-linebreak.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,7 @@ Examples of **correct** code for this rule with the `"below"` option:
If you're not concerned about consistent locations of implicitly returned arrow function expressions, you should not turn on this rule.

You can also disable this rule if you are using the `"always"` option for the [`arrow-body-style`](arrow-body-style), since this will disable the use of implicit returns in arrow functions.

## Version

This rule was introduced in ESLint 4.12.0.
4 changes: 4 additions & 0 deletions docs/src/rules/indent-legacy.md
Original file line number Diff line number Diff line change
Expand Up @@ -539,3 +539,7 @@ var foo = { bar: 1,

* **JSHint**: `indent`
* **JSCS**: [validateIndentation](https://jscs-dev.github.io/rule/validateIndentation)

## Version

This rule was introduced in ESLint 4.0.0-alpha.0.