Should I use arrow functions or class function style
This may be a very stupid question. But I was wondering if I should be using arrow function syntax or the classic function syntax for react components now or is this purely a style choice. I ask this purely as someone trying to work towards industry standards but have found a tremendous amount of mixed comments on it. Also is there any difference using typescript?
Dan Abramov made a convincing (to me) argument for using the named function style. Stack traces will give a more immediately useful information.
It’s not a deal breaker, so in a work context I would tend towards following the existing style as some people are really attached to anonymous functions