Wondering if its possible to disable the animate at the beginning of the loading.
Instead of loading the graph, I wanted to have it loaded immediatly without a delay.
I found thus far: Chart.defaults.global.animation but I have no idea how to implement it.
The reason why I want this is because i'm trying to implement this on the mobile phone, and it seems to be quick, but the animation itself the small second it takes to move the graph around seems to be slow.
Is there any way to disable it?
This should work:
options: {
animation: {
duration: 0
}
}
@zachpanz88 is correct.
Thanks for the quick reply!
Still animates the building of the chart, meaning the height and width are animated.
I'm trying to disable the animation of the width and height of the chart on resize... I cant seem to figure out how to do this
I wish to obtain an instant rendering, no animation, no empty canvas (I have a div with style 'display:none' and when I show it, the graph should appears with no transition or construction visible). Seems that this is impossible with Chart.js.
I wish to obtain an instant rendering, no animation, no empty canvas (I have a div with style 'display:none' and when I show it, the graph should appears with no transition or construction visible). Seems that this is impossible with Chart.js.
Maybe if you give it animation duration of 0 and then use a onComplete hook to make the chart visible?
Still a problem for me as well. Setting duration:0 seems to _speed _up__ the animation, but not prevent it. On first load, there is animation that is taking time and distracting. Wish the width/height wasn't something that animated on first load.
Most helpful comment
This should work: