Update 10.2 as per func-style allowArrowFunction#270
Conversation
|
The current Why? section looks like this
I'm not sure how to update it, especially since
is already there... 🤔 I could add something like
Thoughts @lemonmade? |
lemonmade
left a comment
There was a problem hiding this comment.
I think this is all you need. You could bring in the reasoning that sometimes arrow functions are useful for typing, but I’d like to avoid showing the SFC example because that’s actually not the pattern we would usually lean towards (especially in the context of new stuff in React where they are largely demonstrating features in function declarations)
README.md
Outdated
| const bad = function() {} | ||
|
|
||
| // okay | ||
| const okay = () => {} |
There was a problem hiding this comment.
I think you can mark this as “also good”
72b521f to
465ddd1
Compare
This updates rule 10.2 following the change in Shopify/eslint-plugin-shopify#188 allowing arrow function expressions.