DEV Community

Discussion on: The Power of React Hooks - Create an app using only this feature in React

Collapse
 
jsmanifest profile image
jsmanifest • Edited

Hi Nair. Thank you for the honesty and the suggestion. If that is really the case I might have to figure something out. I written a longer tutorial using the approaches you suggested of going through each step in smaller chunks. The problem with the outcome was that it ended up having a really, really low read ratio and i was having the impression that the length of the post was scaring readers away or people were giving up half way into the tutorial because it felt too long. That was sorta the reason why I wrote this post this way. A solution might be to write my posts in a series like a part one, part two. As a learner reading through tutorials, would that help?

Collapse
 
kvsn_1 profile image
Sasikant

Thanks for responding. Yes, I believe breaking down the project into smaller chunks and posting it in series is a great idea. After finishing each article, the reader should take something concrete out of it. I mean concept wise.

For example, let's assume the first article of the series explains the application of useState() and useEffect(). The reader will learn about the syntax, how to set initial state, how it appears in react dev tools etc. You can have the reader interact with the component and showcase how it is being handled in the react dev tools and which function gets called to update the state compared to setState() in class components.

Then proceed with useEffect() to explain how it compares with lifecycle methods of class based components. You'll be moving forward with your example slotify project as well as the reader will be grasping the Hooks API concepts one by one, seeing it in action, giving the reader opportunity to tinker with it.

Sometimes, you may need to add code/stuff in a post which might not be directly relevant to the slotify project but will contribute while explaining the concepts. When you feel you've explained enough, you can come back to the project and have the reader rewrite the code making them understand the reasoning behind this.

This way, even if the reader doesn't proceed to other posts of the series, they'll remember how the useState() and useEffect() worked. They'll definitely remember the person who taught them :)

My first hands on experience with React Hooks was due to this article by David Katz. I really liked his approach.

medium.com/@dtkatz/react-hooks-tut...