Skip to content

Commit

Permalink
Docs: Clarify arrow function parens in no-extra-parens (fixes #8741) (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
platinumazure authored and not-an-aardvark committed Jun 28, 2017
1 parent 84d921d commit 5c83c99
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docs/rules/no-extra-parens.md
Expand Up @@ -9,6 +9,8 @@ This rule always ignores extra parentheses around the following:
* RegExp literals such as `(/abc/).test(var)` to avoid conflicts with the [wrap-regex](wrap-regex.md) rule
* immediately-invoked function expressions (also known as IIFEs) such as `var x = (function () {})();` and `((function foo() {return 1;})())` to avoid conflicts with the [wrap-iife](wrap-iife.md) rule

In addition, this rule ignores parentheses around arrow function arguments to avoid conflicts with the [arrow-parens](arrow-parens.md) rule.

## Options

This rule has a string option:
Expand Down Expand Up @@ -217,5 +219,6 @@ typeof (a);

## Related Rules

* [arrow-parens](arrow-parens.md)
* [no-cond-assign](no-cond-assign.md)
* [no-return-assign](no-return-assign.md)

0 comments on commit 5c83c99

Please sign in to comment.