Reputation: 95
I have 2 components which I'm adding to app.component html
When I do this it works as normal:
<app-parent></app-parent>
<app-child1></app-child1>
Result is:
parent works!
child1 works!
But when I try this:
<app-parent>
<app-child1></app-child1>
</app-parent>
There is no result displayed.
Can the above not be done?
Upvotes: 0
Views: 131
Reputation: 20374
You need to go in parent.html
file and add <app-child1></app-child1>
as a content.
Upvotes: 1