Closed ricardomariz closed 6 years ago
I'm trying to use annotations and it doesn't seems to work properly.
I'm loading the module like this:
import Annotation from '../../node_modules/highcharts/modules/annotations.js' Annotation(Highcharts)
import Annotation from '../../node_modules/highcharts/modules/annotations.js'
Annotation(Highcharts)
And after that adding some data throught the options:
annotations: [{ labels: [{ point: { x: 5.5, y: 30, xAxis: 0, yAxis: 0 }, text: 'Label' }, { point: { x: 18, xAxis: 0, y: 90, yAxis: 0 }, text: 'Aaaaaaa' }], labelOptions: { backgroundColor: 'rgba(255, 255, 255, 0.5)', borderColor: 'silver' } }],
But when the graph loads, it doesn't show any annotations, just a string "[object Object]" on the top-left corner (as shown in the link).
https://imgur.com/a/Kbs6R
I also tried to add highchartMore module but still not working.
I was using highcharts 5.x instead of highcharts 6.0. Now it's working.
I'm trying to use annotations and it doesn't seems to work properly.
I'm loading the module like this:
import Annotation from '../../node_modules/highcharts/modules/annotations.js'
Annotation(Highcharts)
And after that adding some data throught the options:
annotations: [{ labels: [{ point: { x: 5.5, y: 30, xAxis: 0, yAxis: 0 }, text: 'Label' }, { point: { x: 18, xAxis: 0, y: 90, yAxis: 0 }, text: 'Aaaaaaa' }], labelOptions: { backgroundColor: 'rgba(255, 255, 255, 0.5)', borderColor: 'silver' } }],
But when the graph loads, it doesn't show any annotations, just a string "[object Object]" on the top-left corner (as shown in the link).
https://imgur.com/a/Kbs6R
I also tried to add highchartMore module but still not working.