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 <[email protected]>
Reviewed-By: Tiancheng "Timothy" Gu <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Khaidi Chu <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
  • Loading branch information
Trott authored and MylesBorins committed Jan 8, 2018
1 parent f5234e2 commit b919ac1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions .eslintrc.yaml
Original file line number Diff line number Diff line change
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 b919ac1

Please sign in to comment.