Angular 2 has a " safe navigation operator that allows you to reference potential undefined child properties in your components.
Is there a way to use this with dynamic properties and a bracket? eg.
<input [type]="text" [ngModel]="formValues?[control]">
Where controlis another variable from my component telling the template that forms the value to use, and formValues is loaded async, so it could potentially be null.
source
share