iflix / standard

:star2: JavaScript Standard Style Guide
http://standardjs.com
MIT License
0 stars 0 forks source link

array-callback-return #6

Open obrin opened 7 years ago

obrin commented 7 years ago

(array-callback-return)[http://eslint.org/docs/rules/array-callback-return]

If you're not returning on an array method callback, you're probably using it wrong.

joshgillies commented 7 years ago

Does this error on with the following:

const arr = [1,2,3]
const addOne = (i) => i + 1 // implicit return, shouldn't error
arr.map(addOne)
hizo commented 7 years ago

if example from @joshgillies passes, i'm up for it