In below sample, I have used ng-template
like below and it is working fine.
Sample link: click here
<ng-template #template let-dataSource="">
<span *ngIf="dataSource.iconCss" class="e-menu-icon {{dataSource.iconCss}}"></span> {{dataSource.header}} {{dataSource.text}}
<span *ngIf="dataSource.templateHeader" class="e-login-content">
<button ejs-button cssClass="e-info">Sign In</button>
</span>
</ng-template>
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…