1. (change) is bound to the HTML “onchange” event.
2. (ngModelChange) is bound to the “ngModel” directive.
Example
app.component.html
Change : <input type=”text” (change)=”onChange($event.target.value)”> <p>Value of the field - {{val1}}</p> ngModelChange : <input type=”text” [(ngModel)]=”val” (ngModelChange)=”ngModelChange($event)”> <p>Value of the field - {{val}}</p>
app.component.ts
val; val1; onChange(value) { console.log(“changed called”) this.val1 = value; } ngModelChange(value) { console.log(“ngModelChanged called”); }
Here when the user changes the value in the input tag, the onChange method will be called after the blur event.
While ngModelChange will be called even before the blur event.