3 ms·
> and now ES6 classes and all the rest are deprecated, because Dan Abramov had another idea for again a new design principle that's just less than a year old: H
by azangru 7y ago
> and now ES6 classes and all the rest are deprecated, because Dan Abramov had another idea for again a new design principle that's just less than a year old: Hooks.
This is so off the mark it’s not even funny.
- Dan did not develop the hooks api
- he is also on record saying that people don’t need to re-write their components with hooks
- class components have not been deprecated in React
- siempreb 7y agoIt is indeed not funny, and you're off the mark as well: > Dan did not develop the hooks api I didn't say he developed it > he is also on record saying that people don’t need to re-write their components with hooks So? In my daily work I see it all the time. You think I have a say in that when I have a gig at company X? > class components have not been deprecated in React You've got a point there, indeed not officially deprecated, but in practice(again) at company X, you cannot do classes anymore.
- abacadaba 7y agoAnnoying, but sometimes a better idea comes along. I think me and many others initial reaction to the hooks presentation was 'yeeaaaassss'. Still in mostly es6 class codebase of course, so haven't had a chance to do too much with them yet, but as long as they're not gonna break backwards compatibility, yes please.
- fourthark 7y agoIf people won't even listen to the developers of the tools they use, and insist on "out with the old, in with the new" when those developers are pleading with them not to create extra work for themselves... Whose fault is that?
- vonseel 7y agoThere are even linting rules to ban use of class components, IiRC. You’re not wrong. Hooks are being pushed HARD for new code.