Closed albertleao closed 8 years ago
There are many potential problems that can occur in troubleshooting a hybrid app. It could be project specific, plugin issue, platform specific problem, or maybe an issue with the google analytics setup. I am not experiencing the same issue you are having. I just brought up a clean project by doing the below commands and I could see the app view showing up in GA real time view.
cordova create analytics-test cd analytics-test cordova platform add ios cordova platform add android cordova plugin add ../google-analytics-plugin/ echo "document.addEventListener('deviceready', function () {\n var analytics = navigator.analytics;\n\n analytics.setTrackingId('UA-XXXXXXX-1', function () {\n analytics.sendAppView('home');\n });\n}, false);" >> www/js/index.js
You might want to try do the same with your tracking id and see if that works. If that works that it might be an issue with the project setup. Hope that helps.
When configuring the analytics account, we need to select mobile app or web app?
@leandroz You need to use Mobile App.
My GA real time dashboard shows that my user is online, but even when sending
analytics.sendAppView('home', successCallback, errorCallback);
and getting a callback of 'OK' but the active page does not update