This repo contains code from the blog post 5 Ways to convert react class components to functional components with hooks
The blog posts discuses how to refactor 5 types of React component classes to have the same behavior with Hooks
In class we will mount the component to App, view the code and discuss how it works
Next we will go to another blog Why react hooks and how did we get here to understand
- The benefits of using Hooks as opposed to classes in your new components.
- Some rules we need to keep in mind when using Hooks
The last blog article Simple code reuse with react hooks is another example of how to build your own custom hook