DEV Community

Discussion on: How to use the State Hook in React

Collapse
 
damcosset profile image
Damien Cosset

Indeed, I talk about the disappearance of variables in the context of React components and re-rendering to explain what state is. I understand it could be difficult to understand, and I should have make it clearer in my article.

As for the fact that something new is yet added to the library, I can understand your frustration. I shared that feeling when I felt like I was finally starting to get React pre-hooks, something new was coming up... I didn't want to learn hooks until a few months ago, even after updating my React versions. I appreciate the fact that the React team added hooks without any breaking changes for my pre-hook code.

I felt like I had to learn hooks because I was working with React so much. I do enjoy the way my code looks with Hooks, compared with classes :)