How to Use React Hooks to Monitor Events in Your App

Justin Hunter
Level Up Coding
Published in
9 min readJan 19, 2021

--

The introduction of Hooks in React was a game-changer. Developers now had options when it came to creating stateful components. It used to be that if you had a stateful component, you’d have to use a class component, and if you had a presentational component, you could choose between a class or a function component. Now, with hooks, state can be managed inside function components. But that’s not all Hooks did for React developers.

Hooks introduced a better way to reuse stateful functions. Today, we’re going to explore how to build a custom…

--

--