如何在Angular 2的“选择”中获得新选择?
我正在使用Angular 2(TypeScript)。 我想对新选择进行某些操作,但是我得到的onChange()总是最后一个选择。如何获得新选择? <select [(ngModel)]="selectedDevice" (change)="onChange($event)"> <option *ngFor="#i of devices">{{i}}</option> </select> onChange($event) { console.log(this.selectedDevice); // I want to do something here with the new selectedDevice, but what I // get here is always the last selection, not the one I just selected. }