carlcraig / tc-angular-chartjs

AngularJS directives for Chart.js
http://carlcraig.github.io/tc-angular-chartjs/
Other
233 stars 83 forks source link

let the browser render the DOM before resizing the chart #46

Closed jengeb closed 8 years ago

jengeb commented 9 years ago

This commit uses setTimeout() in order to wait until the browser has rendered the DOM. This fixes an issue in my application where the chart isn't rendered on page load.

jengeb commented 9 years ago

Do you have any idea why the test is failing? It also fails with the current master (b4445bbddf402df9dde7380b1e77e557bd0fbc86).

andrenarchy commented 9 years ago

Perhaps a dependency has been updated?

carlcraig commented 9 years ago

The current version seems to be passing: https://travis-ci.org/carlcraig/tc-angular-chartjs/builds although I will check if there is some issue with packages for tests.

If you could also look into the tests to see if we can work out where they are breaking it would be great.

You can run grunt watch locally to run all the tests.

Other than the tests failing, it looks like a good fix.

carlcraig commented 9 years ago

Theres definitely something going wrong with the builds, as I have re-run the latest commit and it now fails, even with all tests passing: https://travis-ci.org/carlcraig/tc-angular-chartjs/builds/62941570

jengeb commented 9 years ago

I don't know what's wrong here, can you investigate the issue? Thank you!

carlcraig commented 8 years ago

the new 2.1.X version is using chart.js 2.X ... if you still have this problem with updated libraries, please re-open this.

going to close this for now as there are conflicts.