I have a widget base Angular 4 application. This application will have a different type of widgets and any of them will be a different component. At the moment I have just wanted one type of widget and the HTML looks like this
<div [ngGrid]="gridConfig">
<div *ngFor="let widget of widgets;">
<widget [id]="widget.id" [widgetConfig]="widget.config"></widget>
</div></div>
I have searched the web but every solution I have found doesn't seem to fit my case.
Is there any way where I can add the selector dynamically like this<{{widget.selector}} [id]="widget.id" [widgetConfig]="widget.config"></{{widget.selector}}>
, Where selector would be the selector of the specific widget component.