Hi
I am trying to implement GA to my mobile android app and I got stuck at “sessionId is not defined” error:
Uncaught (in promise) ReferenceError: sessionId is not defined
at eval (google-analytics.js?91fb:5)
at eval (vue-router.esm.js?4af9:2176)
at Array.forEach (<anonymous>)
at HashHistory.updateRoute (vue-router.esm.js?4af9:2175)
at eval (vue-router.esm.js?4af9:2037)
at eval (vue-router.esm.js?4af9:2159)
at step (vue-router.esm.js?4af9:1843)
at step (vue-router.esm.js?4af9:1850)
at step (vue-router.esm.js?4af9:1850)
at runQueue (vue-router.esm.js?4af9:1854)
in file “google-analytics.js?91fb:5”
import ga from '../analytics.js'
export default ({ router }) => {
router.afterEach((to, from) => {
ga.logPage(to.path, to.name, sessionId)
})
}
I created everything following tutorial from Quasar help and Multiminds tutorial but I can not figure out why the SessionID is undefined.
I tried to set it as constant and the result is the same.
I also installed the app on my cellphone but I can not see any data on Google analytics.
Does anyone has any idea what am I doing wrong?
thanks
A.