Hacker News new | past | comments | ask | show | jobs | submit login

To me, hooks allow to do class-based components without class. I do not exactly see the point. What is wrong with class-based components?



It is not cool


To Vue's credit, Evan has been absolutely up front and has made his rationale clear for why class based components were abandoned:

https://github.com/vuejs/rfcs/pull/17#issuecomment-494242121

You can't ask for more than that from someone who disagrees and is in control of the project. Also he's doing a pretty awesome job maintaining the project.


Isn't this conversation about React?


> What is wrong with class-based components?

The posted link contains a detailed breakdown written by Vue's creator of why Vue, a similar tool to React chose to de-emphasize class-based components in favor of the composition API (hooks).

I thought you might be able to find some clues to why people pick hooks over class-based components in there.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: