Hi eraka!
It is hard to tell you what is not working and what could be done without taking look at your code. Could you reproduce the issue in an online editor that I could work on? You can start here: https://codesandbox.io/s/highcharts-rea ... =/demo.jsx
The error message is saying everything you need to know. You are trying to use a variable before its initialization. Sadly, I can't tell you what is not working and what could be done without taking look at your code, so please reproduce it in some online editor.