Gabe Alexander
Posts: 2
Joined: Mon Nov 01, 2021 8:15 pm

Highcharts error handling

Under certain conditions when using some stock tools I get errors ranging from ``` TypeError: Cannot read properties of null (reading 'isCartesian')``` to ```TypeError: g.onMouseOut is not a function``` that break the whole chart, and while I'm sure there's a way to avoid these I would like if I could just throw an error and destroy and recreate the chart. I have been unable to find an event to catch these to add any custom logic to. So I guess really my question is just how can I catch these errors from highstock.js
mateusz.b
Posts: 2006
Joined: Tue Jul 13, 2021 11:34 am

Re: Highcharts error handling

Hi Gabe Alexander,

Thanks for contacting us with your issue.

It is hard to tell without taking a look at your code. You said that the error happens under certain conditions. Please try to create a live demo and provide me with detailed description and steps to reproduce that issue. I don't know what technology you use but you can try to start here:
https://stackblitz.com/edit/highcharts- ... basic-line

Regards!
Mateusz Bernacik
Highcharts Developer

Return to “Highcharts Stock”