Comments (3)
Hello rolandvincze,
Thanks for contacting us and bringing up this problem!
By default, Highcharts creates a reference to the provided data, not a direct copy, so data points seem overridden during the rerenders after the initial one. Nevertheless, I wouldn't classify it as a bug since by definition id
should be a unique value that Highcharts handles as expected. I'd also expect a warning message in the console indicating that using the repeated IDs may lead to some unexpected behaviors. Since the change should be made to the Highcharts core code, feel free to report it here.
What you can do is change the Highcharts's initial data mutation by using the chart.allowMutatingData property set to false to create a direct copy of the provided data. Please refer to your updated example and the API reference.
Kind Regards!
from highcharts-react.
Hi @KamilKubik,
Thank you for the answer! I would have another question regarding this, does this change come with any other side effect besides possible performance issues? (I'm interested in side-effects functionality-wise mainly).
Kind Regards!
from highcharts-react.
From the Highcharts perspective, the mentioned copy is created based on your initial data only. Since this functionality refers to the data directly, I assume the only side effects you can potentially face are related to updating the data. Nevertheless, you shouldn't encounter any apart from the possible performance issues. What I'd potentially expect is the rerendering issues related to React. But I'd be concerned about this only when you face it (your case is a bit specific, and I haven't found any related threads) - feel free to share your code in that scenario.
Regards!
from highcharts-react.
Related Issues (20)
- Unexpected series order when adding linkedTo series HOT 2
- Cannot read properties of undefined (reading 'forEach') HOT 4
- Server side rendering of React components HOT 2
- Issue with borderRadius object HOT 1
- i am unable to draw a Polar (Radar) chart HOT 2
- Is this the correct way to use the Boost module to improve performance? HOT 3
- Updating a column chart's series data with dataSorting: enabled causes a crash HOT 2
- Bar Chart Rendering is different if I use boost HOT 4
- Leaving the page with a highstock chart in it throws multiple console errors despite chart doing its job HOT 4
- Issue: Component Getting Unmounted from DOM When Using Scroll HOT 4
- Issue: Inconsistent Space Between Axis and Scroll Bar When Scrolling and Zooming in Chart HOT 3
- Incorrect Typescript usage documentation HOT 1
- Scroll Wobble in Highcharts/Stock HOT 2
- Charts resize infinitely when placed under a flexbox with flex-direction: column HOT 2
- mapline is hidden when draw from LA to Taiwan HOT 1
- How to add new y axis? HOT 2
- I'm trying to find a way to center my flag but can't seem to do it #21540 HOT 1
- Cannot center data label HOT 1
- Can i add a marker at the end of the path Gauge? HOT 2
- Question: Remove 1/2 solidchart HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from highcharts-react.