runars
Posts: 3
Joined: Wed Apr 07, 2021 10:56 pm

X-range setExtremes

Hi,

I am trying to set the extremes for an X-range chart with live data. When the data points are disappearing (by increasing the min extreme for example), this message is spammed in the console:

Image

See this jsfiddle for reproduction of error: https://jsfiddle.net/yLea9t13/12/

Please note that the error does not show up in the jsfiddle console, but in the browser console.

How can this be prevented?

Thank you!
User avatar
sebastian.h
Posts: 1734
Joined: Fri Aug 07, 2020 7:08 am

Re: X-range setExtremes

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

Have you tried to load data in events load, like in this example?
https://jsfiddle.net/gh/get/library/pur ... mic-update

Simple template:
https://jsfiddle.net/BlackLabel/s8176oq9/

Let me know how are you going with this.
Best regards.
Sebastian Hajdus
Highcharts Developer
runars
Posts: 3
Joined: Wed Apr 07, 2021 10:56 pm

Re: X-range setExtremes

Thank you for trying to help me. The problem is not about adding new data to the chart, but changing the extremes. By changing the extremes in events load, the same happens.

See this jsfiddle: https://jsfiddle.net/y1ognv2t/16/

When the blue bar is outside the visible area, the console in the browser is spammed with messages like Error: <rect> attribute width: Expected length, "6.51722370773771…"
User avatar
sebastian.h
Posts: 1734
Joined: Fri Aug 07, 2020 7:08 am

Re: X-range setExtremes

Hi,
Thanks for clarifying,

After investigation, it's probably a bug, I found a similar GitHub issue, you can report there and show your example.
https://github.com/highcharts/highchart ... issues/207

Demo:
https://jsfiddle.net/BlackLabel/8fo7j05e/

Best regards!
Sebastian Hajdus
Highcharts Developer

Return to “Highcharts Usage”