GoConqr has a new look! Let us know what you think.

Module 15 of 28 · Media

Props.children

Kostas Diakogiannis

Props.children

Components render other components

A very common use is that components, except JSX can also render other compnents. That means that a component acts as a parent-component and inside renders other components and whatever these render.

During rendering phase, myHeading  has another component inside. That means that potentially this NavBefore component can be placed somewhere inside the MyHeading render function.

There is no designated place for that. It can be put either before, after or somewhere between. In order to specify that, we use the {this.props.children} inside the MyHeading render function, in order to specify where the NavBefore component should be rendered.

Instructions

You must submit an attempt for this quiz to progress. You can submit it after the last question.

Go to the chosen module

Feedback

What is it about?

What do you think of the new look?

How do you like it?