Angular / Angular basics
Explain <ng-container> element in Angular.
<ng-container> is a grouping element that does NOT interfere with styles or layout because Angular doesn't put this element in the DOM.
The <ng-container> is a syntax element recognized by the Angular parser. It is not a directive, component, class, or interface. This element can replace a span tag as you may want to eliminate any styles associated with the span element, also ng-container can be used for conditional select-option list. In short, use <ng-container> as a grouping element when there is no suitable host element.
More Related questions...