im able to select February 31 from the date picker … this happen only when i select march 31 then again i go to February i was able to select . How to restrict or Refresh this…?
startdate;
endDate;
maxDate = moment.utc().add(90, ‘d’).format(‘YYYY-MM-DD’);
minStartDate(): string {
return moment().format(‘YYYY-MM-DD’);
}
minEndDate(): string {
return moment(this.startdate).add(0, ‘day’).format(‘YYYY-MM-DD’);
}
changeEndDate(): void {
if (moment(this.startdate).isSameOrAfter(this.endDate)) {
this.endDate = moment(this.startdate).add(0, ‘day’).format(‘YYYY-MM-DD’);
}
}