chartjs / chartjs-plugin-deferred

Chart.js plugin to defer initial chart updates
https://chartjs-plugin-deferred.netlify.app/
MIT License
110 stars 21 forks source link

Doesn't work with fullPage.js #1

Closed newUserForTesting closed 8 years ago

newUserForTesting commented 8 years ago

This plugin looks great! But as soon as I included chartjs-plugin-deferred.min.js, all of my existing charts stopped working. Could someone please provide workaround or fix for this issue?

newUserForTesting commented 8 years ago

Update: Plugin doesn't work with pages where https://github.com/alvarotrigo/fullPage.js is used. Could someone please provide workaround or fix for this issue?

simonbrunel commented 8 years ago

This plugin works only with native scrolling but it seems that fullPage.js relies on CSS transforms instead, so unfortunately, this plugin will not work in that case.

newUserForTesting commented 8 years ago

That is sad :( This was a great plugin and made our pages look super cool, unfortunately for us that we can't make use of it now :( Thanks a lot for your prompt reply :)

simonbrunel commented 8 years ago

Though, you might want to have a look to the fullPage.js FAQ, there are useful information that could help to workaround your issue, especially this answer suggesting to use the scrollBar: true option for fullPage.js.

newUserForTesting commented 8 years ago

I will quickly check it out! Thanks a lot for providing your precious time to us :)

newUserForTesting commented 8 years ago

Thanks a lot! scrollBar:true worked! Once again, this plugin is amazing! One doubt, is it possible to rerender the charts everytime(just like chartjs-plugin-deferred is doing the first time) the canvas appears inside the viewport? This would make is supercool!

simonbrunel commented 8 years ago

Glad to hear that it works with fullPage.js :)

This plugin doesn't allow to reload the chart once it has appeared on screen and actually, scroll listeners are removed as soon as the chart is fully loaded. You can create a new feature request with details about how you expect it to work, but there is no obvious solution right now, so that might not be implemented anytime soon.

Closing this ticket since a solution has been found for the reported issue.

newUserForTesting commented 8 years ago

Sure, I will create a feature request with required details. Thanks a ton for your help :)