react-jsx-highcharts
react-jsx-highcharts copied to clipboard
Ability to export a graph
Feature Request
Description
Be able to use the useChart Hook to access other methods on the Chart class
@anajavi Is there any reason they haven't been added in already, i see there is a few added in without types currently.
It can be added in here, but I am not able to create a branch to open a PR currently!
packages/react-jsx-highcharts/src/components/BaseChart/createProvidedChart.js

Given its a one line change, perhaps you can make a pull request for this?
- Fork this repo
- Make your changes
- Create a pull request against this repo
The chart is already accessible with useChart:
const c = useChart();
const chart = c.object;
I am trying to access the "exportChart" method, which doesn't exist on the chart obj
Looking to add it to the exposed interface in "BaseChart/createProvidedChart.js" or wherever it should fit
I am trying to access the "exportChart" method, which doesn't exist on the chart obj
There probably isn't typescript definition for exportChart as it is added via highcharts module.
Did you try to run your code ignoring typescript warnings for exportChart?
https://github.com/whawker/react-jsx-highcharts/pull/375 Hey, why aren't you merging this?