DEV Community

Discussion on: Calling Child Component Function From Parrent Component ( forwardRef and useImperativeHandle)

Collapse
 
ekeijl profile image
Edwin • Edited

The information here is technically correct, but should only be used as a last resort, for example when you're integrating with a third party library that is hard to integrate with React and requires you to call a function on it directly.

In 99.9% of the cases, you want to communicate with the ChildComponent by passing it new props that reflect the update.