I am building an angular 8 application. I have a nested component which I would like to dynamically add on the parent component on clicking of a button on the parent component. Something like this below: 
The ADD button should add the component on the parent component. The close button should remove the nested component from the parent component. Also, I would like communication between parent and nested component to happen on clicking some controls on the nested component, like clicking on the Add Student button etc. So far I have been able to create a nested component and add it on the parent component (not dynamic).
Please find the code below:
add-student.component.html
<div class="col-lg-3 col-md-12">
<div style="float: right;">
<button type="button" class="close" aria-label="Close">
<span aria-hidden="true">×</span>
</button>
<button type="button" class="btn btn-primary">Add Student</button>
</div>
I know that I can use jquery to dynamically add divs and achieve this. But how can I achieve this using angular ? Is there a better and easier way to accomplish this ?
Thanks