React Hooks HowTo: Unleashing the power of side effects using useEffect() Hook in React



React Hooks HowTo: Unleashing the power of side effects using useEffect() Hook in React

React Hooks HowTo: Unleashing the power of side effects using useEffect() Hook in React

This is an excerpt from one of my longer videos. Watch the full video here 👉 https://youtu.be/EzI-k5lqIng

The current version of the Yeoman generator for the SPFx still uses the older-style React class components. Because that’s what you get by default, that’s what most developers end up using.

But functional components enabled by React hooks have become widely popular… and I get a lot of questions on how to use React hooks in your SharePoint projects!

So… until Microsoft updates the Yeoman generator, I’m going to show you how you change your new projects to React hooks in just a few minutes.

And then, I’ll show you the basics of hooks with a simple example.