8000 add composing-components.md · learnreactjs/learnreactjs@ece5267 · GitHub
[go: up one dir, main page]

Skip to content

Commit ece5267

Browse files
committed
add composing-components.md
1 parent 288ec79 commit ece5267

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Composing Components
2+
3+
React components can make use of other React components. When a component contains another component it can be said that the parent component owns the child component (composition).
4+
5+
In the code below the `ParentComponent` component contains/owns the `FirstChildComponent` and `SecondChildComponent` component.
6+
7+
<p data-height="265" data-theme-id="dark" data-slug-hash="Vxqgpo" data-default-tab="js,result" data-user="Bunlong" data-embed-version="2" data-pen-title="Vxqgpo" class="codepen">See the Pen <a href="https://codepen.io/Bunlong/pen/Vxqgpo/">Vxqgpo</a> by Bunlong (<a href="https://codepen.io/Bunlong">@Bunlong</a>) on <a href="https://codepen.io">CodePen</a>.</p>
8+
<script async src="https://static.codepen.io/assets/embed/ei.js"></script>

0 commit comments

Comments
 (0)
0