M
M
Maxim Zolotoy2020-04-25 17:48:05
JavaScript
Maxim Zolotoy, 2020-04-25 17:48:05

How can I simply pass the Ref of the parent to the child in React?

5ea44d562570e690078491.jpeg

React first draws the component that is inside - MiniMap
And then the parent and therefore the passed Ref will not be available in the DidMount method in the child component.
How can I normally get the Ref of a parent in a child component?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question