Skip to content

Commit

Permalink
tools: enable array-callback-return ESLint rule
Browse files Browse the repository at this point in the history
For array methods that depend on a callback (such as `.filter()` or
`.map()`), require a return value from the callback.

PR-URL: #17858
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Khaidi Chu <i@2333.moe>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
  • Loading branch information
Trott authored and MylesBorins committed Jan 9, 2018
1 parent 2759709 commit 4391ea4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions .eslintrc.yaml
Expand Up @@ -43,6 +43,7 @@ rules:
# Best Practices
# http://eslint.org/docs/rules/#best-practices
accessor-pairs: error
array-callback-return: error
dot-location: [error, property]
eqeqeq: [error, smart]
no-fallthrough: error
Expand Down

0 comments on commit 4391ea4

Please sign in to comment.