在Angular 2中,我创建了一个带有动态选项的选项,选项(项目数组)将被更改
<select [(ngModel)]="itemFilter" (change)="onChange($event)">
<option *ngFor="let item of items" [ngValue]="item.name">{{item.name}}</option>
</select>
我假设ngModel值为“abc”,但选项(项目数组)已更改,然后ngModel绑定被破坏,因此所选项目变为空白
有没有人遇到过类似的问题?