I'm using:
- material-dayjs-adapter: 2.0.0
- dayjs 1.10.5
- angular & angular material 12.1.1
When using a custom date format the datepicker does not recognize the user typing in a date due to an error:
ERROR TypeError: Cannot read properties of undefined (reading 'replace')
at :4200/vendor.js:95004
at a (:4200/vendor.js:95004)
at Object.longDateFormat (:4200/vendor.js:95004)
at DayjsDateAdapter.parse (:4200/main.js:130)
at MatDatepickerInput._onInput (:4200/vendor.js:87072)
at MatDatepickerInput_input_HostBindingHandler (:4200/vendor.js:87130)
at executeListenerWithErrorHandling (:4200/vendor.js:48548)
at wrapListenerIn_markDirtyAndPreventDefault (:4200/vendor.js:48597)
at HTMLInputElement.<anonymous> (:4200/vendor.js:92678)
at ZoneDelegate.invokeTask (:4200/polyfills.js:412)
This appears to be due to a change in dayjs longDateFormat in a recent version
I'm using:
When using a custom date format the datepicker does not recognize the user typing in a date due to an error:
This appears to be due to a change in dayjs longDateFormat in a recent version