问题
Noob question: I'm trying out the new Angular.js framework but can't seem to get my sparklines to display on my partials. The arrays I want graphed do display in text.
It seems to be a problem with when the string loads on the page and when Sparklines are called. I'm calling the jQuery sparklines in the <head>
.
How do I get these to display in an ng-repeat?
回答1:
Check out the JQuery wrapper from the AngularUI project:
https://github.com/angular-ui/angular-ui/blob/master/modules/directives/jq/jq.js
The issue is with plugins that change the DOM without alerting AngularJS to the change.
来源:https://stackoverflow.com/questions/12182214/angular-js-with-jquery-sparklines