I'm trying to format my date value to M/d/yy
using the Angular datepipe. It works in localhost wery well but when to deploy on remote server - the datepipe sets an incorrect format - YYYY-MM-DD HH-MM
.
There my code:
@Component({
selector: 'app-date',
template:
'<span>{{ curDate | date: this.dateFormat }}</span>',
})
export class DateComponent<M> extends BaseComponent<M> {
dateFormat = 'M/d/yy';
curDate = this.date // 2021-03-24T07:57:50.711Z
}
Can someone help me with this?