Angular Framework + Google Visualization API

56 views
Skip to first unread message

Raj

unread,
Aug 21, 2015, 12:27:40 PM8/21/15
to Google Visualization API
Hi



I am trying to use charts in Angular framework.

I want to add different listeners to chart. How can i add it.


1)I do not know when is the appropriate time in angular to add the listener.

2)
<div google-chart chart="chart" style="{{chart.cssStyle}}" id="gchart"></div>

When i try to access the element like [angular.element(gchart)]..i get error gchart is not defined


3) I tried

$scope.$watch(function(scope) { return scope.chart },
              function(newValue, oldValue) {
                    console.log("this should work");
              }
             );

but i do not know how to type cast newValue?


Any sample having angular and Google Visualization API code will be helpful.


Regards
Raj



seth isernhagen

unread,
Aug 25, 2015, 4:06:29 PM8/25/15
to Google Visualization API
Reply all
Reply to author
Forward
0 new messages