Ng-template / view-container

Hi,
Following the examples in this video - https://www.youtube.com/watch?v=vz9cNCkaPsY&t=4189s
It means that this code:
<button (click)=“remove()”>Remove child component
<a-comp #c>

is it a bad practice?
Does custom element (component) always needs to be wrap with ng-template in order to be a part of angular view container?

I’m not sure what you’re asking. @m.koretskyi maybe you can answer this one, since it’s your workshop in the video.

No, you can use dynamic components approach to create a component and add it to the view container. You need to wrap HTML into the template if it contains something that isn’t just a component, like

<div>
  <h1>Some title</h1>
  <my-component/>
</div>

as opposed to plain

<my-component/>

which can be rendered using dynamic component’s approach.

It’s not exactly clear here what you’re asking, can you elaborate?