Chartjs-Null values for instead of date causes the browser to crash while using chart js

0๐Ÿ‘

โœ…

I downgraded chart.js version from 2.8.0 to 2.6.0 and this worked for me. I think there is any bug in the latest (2.8.0) version of the chart.js.

0๐Ÿ‘

I guess momentjs doesnโ€™t like trying to convert null to a date. So I would recommend checking for null before you provide it to momentjs or think about some default value โ€“ which is a date, but donโ€™t use null.

If you donโ€™t care, you can put

moment().format() // instead of null

Leave a comment