parent.component.html
<div>
<child-component></child-component>
</div>
child.component.ts
@Component({ selector: 'child-component' })
export class ChildComponent {}
This is a very quick way to show how Angular components can be nested. In this example you have a parent component template file (parent.component.html) and inside this file you can include any other component by their selector. In the example I include 'child-component' and show child component ts file.
If you want to make child component dynamic (if I understand you correctly - to pass data from parent to child) and for example pass string value into it, you can:
parent.component.html
<div>
<child-component name="Andrei"></child-component>
</div>
child.component.ts
@Component({ selector: 'child-component' })
export class ChildComponent {
@Input() name: String;
}
More on Angular components communication: https://angular.io/guide/component-interaction