Calling Angulartics functions gives error

250 views Asked by At

I want to use angulartics. I have added "angulartics" and "angulartics.google.analytics" But when I call $analyticsProvider.firstPageview(true); from my config function in app.js it gives me error.

1

There are 1 answers

0
twitch On

Solved it I had to add it as a name variable as well

myApp.config(['$routeProvider','$analyticsProvider', function($routeProvider,$analyticsProvider){ $analyticsProvider.firstPageview(true); $analyticsProvider.withAutoBase(true); .... }]);