Answer the question
In order to leave comments, you need to log in
What is {this.props.children} and when should you use it?
Being new to the React world, I want to understand in depth what happens when I use {this.props.children} and in what situations to use it?
Answer the question
In order to leave comments, you need to log in
Children gets an array of elements that are "inside" the component. For example, in this case:
<SomeComponent>
<ChildComponent />
<ChildComponent />
<ChildComponent />
</SomeComponent>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question