Closed andresbeltran69 closed 3 years ago
Error "Cannot read property 'getUTCFullYear' of null" after nodemod/calendar.js update. app-datepicker not showing.
open app-datepicker
Error "Cannot read property 'getUTCFullYear' of null" and doesn't show the element.
app-datepicker
After nodemod/calendar.js was updated the calendar options names changed. In this case "selectedDate" changed to "date" on
https://github.com/motss/nodemod/blob/d5f5a4c81ee4defd741ea0fd39a8fa748539ba54/src/calendar/calendar.ts#L28
So in order to get the date from
https://github.com/motss/app-datepicker/blob/cbdaa74f762388176ce98200497dd21b6281ed27/src/helpers/get-multi-calendars.ts#L116
the name of the variables need to match. That worked for me.
Thanks for reporting this. This has been fixed in 9d85e7d642cd872ee483dc3fc0e0bf6cbdb27171.
Description
Error "Cannot read property 'getUTCFullYear' of null" after nodemod/calendar.js update. app-datepicker not showing.
Expected outcome
open app-datepicker
Actual outcome
Error "Cannot read property 'getUTCFullYear' of null" and doesn't show the element.
Steps to reproduce
app-datepicker
element in the page.app-datepicker
element.Browsers Affected
Possible solution.
After nodemod/calendar.js was updated the calendar options names changed. In this case "selectedDate" changed to "date" on
https://github.com/motss/nodemod/blob/d5f5a4c81ee4defd741ea0fd39a8fa748539ba54/src/calendar/calendar.ts#L28
So in order to get the date from
https://github.com/motss/app-datepicker/blob/cbdaa74f762388176ce98200497dd21b6281ed27/src/helpers/get-multi-calendars.ts#L116
the name of the variables need to match. That worked for me.