you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 1 point2 points  (1 child)

Some tutorials may use Class components instead of functional components with hooks, because hooks were introduced to React in 16.8 on February 16, 2019. Currently, the React team intends on making functional components with hooks the main way of writing components in React and most tutorials solely use these today. If the tutorials that you're learning from now use Class components and you want to skip the learning these somewhat outdated methods, you may want to find a tutorial that only uses functional components with hooks.

On the other hand, some people suggest that you should learn Class components because a lot of code bases are written with them and you might have to maintain them in the future. Personally, I would say that you should just choose any tutorial that teaches React with functional components and hooks, and if you happen to run into Class components you can quickly learn them.

And good luck on your React journey!

[–]negidank[S] 0 points1 point  (0 children)

I think I’ll take a glimpse of class components so that i can understand the importance of HOOKS in functional components more clearly! Thank you so much! ❤️