I am using react-highcharts and trying to implement ReactHighstock. My charts are showing 'G' instead of 'B'(billions), to fix this I have to set numericSymbols in Highcharts.setOptions but I am not finding a way on how to implement it.
Thanks
I am using react-highcharts and trying to implement ReactHighstock. My charts are showing 'G' instead of 'B'(billions), to fix this I have to set numericSymbols in Highcharts.setOptions but I am not finding a way on how to implement it.
Thanks
You can define Highcharts.setOptions just before coding the class component.
Demo: https://codesandbox.io/s/highcharts-react-demo-n3mes
Highcharts.setOptions({
lang: {
numericSymbols: ["k", "M", "B", "T", "P", "E"]
}
});
API: https://api.highcharts.com/highcharts/lang.numericSymbols
If you are using a functional component then this might helps.
import ReactHighcharts from 'react-highcharts/ReactHighstock.src';
useEffect(() => {
ReactHighcharts.Highcharts.setOptions({
lang: {
numericSymbols: ["k", "M", "B", "T", "P", "E"]
}
});
}, []);