How can I create a component with a HighCharts chart, that create the chart ones on the first render and only update the series data when new data comes in using chart.series[0].setData(data,true);
相关问题
- How to toggle on Order in ReactJS
- Refreshing page gives Cannot GET /page_url in reac
- Adding a timeout to a render function in ReactJS
- React Native Inline style for multiple Text in sin
- Issue with React.PropTypes.func.isRequired
相关文章
- Why would we use useEffect without a dependency ar
- Is it possible to get ref of props.children?
- Stateless function components cannot be given refs
- React testing library: Test attribute / prop
- React/JestJS/Enzyme: How to test for ref function?
- Material-UI [v0.x] RaisedButton on hover styles
- Change color of bars depending on value in Highcha
- Remove expo from react native
I have made a library called React JSX Highcharts, which might be what you're looking for. GitHub / NPM
It allows you to create Highcharts charts with React components. So to update the series data, would just need to pass an updated
data
prop.Behind the scenes, React JSX Highcharts would call
setData
for you.Example
just like this,it works for me.
As stated, you can use react-highcharts. It provides an example of how to update the chart on it's readme page: