I have this expression in my angular HTML form.
<mat-form-field (keydown.enter)="$event.preventDefault()" >
<input id="StartDate" matInput placeholder="Start Date" name="start" [textMask]="mask" [(ngModel)]="RecLoadData.startDate | date:'MM/dd/yyyy'" (ngModelChange)="RecLoadData.startDate=$event" (blur)="onBlurOpenAndCodeDate($event.target.value, 1)">
</mat-form-field>
I keep getting an error saying:
Parser Error: Cannot have a pipe in an action expression at column 25 in [RecLoadData.startDate | date:'MM/dd/yyyy'=$event] in c:/RecLoad/RecLoadAng/src/app/Recload/Recload.component.html@22:110ng(0)
Parser Error: Unexpected token , expected identifier or keyword at the end of the expression [RecLoadData.startDate | date:'MM/dd/yyyy'=$event] in c:/RecLoad/RecLoadAng/src/app/Recload/Recload.component.html@22:110ng(0)
I am already using (ngModelChange) which is suggested in another post. This post is not a duplicate.
Any help will be highly appreciated.