Get X. getPixelForValue(i) in a Chartjs Plugin with a Time Type Scale
I Have a Barchart with Chartjs. the X Scale Is of Type: Time, Data/Ticks Represented Hourly. I Wrote a Cutom Plugin That Draws Something on Canvas...
I have a barchart with chartjs. The x scale is of type: time, data/ticks represented hourly. I wrote a cutom plugin that draws something on canvas. Unfortunately I always get a -32768 for x.getPixelForValue(i), the y.getPixelForValue(i) seems fine. Am I missed something important or chartjs doesn`t support getPixelForValue on time series bar charts?
1 Answer
In the meantime I figured out the issue... The x.getPixelForTick(i) function returns the correct x coordinate for the bars.