WeCodeAcademy

Children and Composition

A component can wrap other content. Whatever you put between its tags arrives as the children prop. This is how you build layouts, cards and buttons you can reuse.

Examplereact
Open in editor »
Quick check

What is the `children` prop?

Finish the quick check (and any code exercise) to complete this lesson, or mark it done yourself.

Tip: use the left and right arrow keys to move between lessons.