DEV Community

Discussion on: An In-Depth Look at the React Lifecycle Methods

Collapse
 
pcelac profile image
Aleks

Too bad that class Components are so 2020, functinal Components are now prefered way to go.

Collapse
 
shafia profile image
Shafia Rahman Chowdhury

Yeah, I have also used functional components so far in my projects but I thought it would be easier for the beginners to understand the lifecycle methods better if I implement them using class components on my demonstrations rather than using functional components.

I have heard that the class components will get deprecated because of the hooks, but I have also heard that you cannot access all the lifecycle methods using hooks. Why is it getting removed then? Any thoughts?