advanced-react-patterns-ultrasimplified
advanced-react-patterns-ultrasimplified copied to clipboard
#09: State Initializers
What is this PR about? 🤔
Make it possible for users to initialise and reset the internal state of the component
Changes 🎁
- [x] Exposed a reset callback
- [x] Handled reset side effects
- [x] Tweaked the UI to reflect a possible use case
Before/After 📸
https://advanced-react-patterns-ultrasimplified.netlify.com/state-initializers
Other comments 💬
NA