Page 1 of 1

Highcharts extension not working in v9

Posted: Fri Nov 26, 2021 4:24 am
by dsilletti
Hi,

I was successfully extending Highcharts v8.2.2. to draw arrows on the line charts:

http://jsfiddle.net/v45wLcf6/

But the same code it's not working with v9:

http://jsfiddle.net/vyfsf1ft/18/

It's possible to make the extension working also with Highcharts v9?

Thank you.

Kind Regards,
Domenico

Re: Highcharts extension not working in v9

Posted: Fri Nov 26, 2021 2:11 pm
by michal.f
Hello Domenico

Welcome to our forum and thanks for contacting us with your question!

The prototype drawGraph function was split for each series type so that wrap pointed to a function that does not exist (line 7). I am sending a demo with a working wrap in the latest version.

Demo: http://jsfiddle.net/BlackLabel/r4qLwy89/

Let me know if you have any further questions!
Best regards!

Re: Highcharts extension not working in v9

Posted: Fri Nov 26, 2021 10:06 pm
by dsilletti
Thank you Michal,

I replaced

Code: Select all

H.wrap(H.Series.prototype, 'drawGraph', function (proceed)
with

Code: Select all

H.wrap(H.seriesTypes.line.prototype, 'drawGraph', function(proceed)
and the code it's perfectly working in Highcharts v9.

Best Regards,
Domenico

Re: Highcharts extension not working in v9

Posted: Mon Nov 29, 2021 8:02 am
by michal.f
You're welcome!

Feel free to ask any further questions!
Best regards!