fix open web analytics tracking
This commit is contained in:
parent
5776def861
commit
aa6d5ee183
|
@ -30,6 +30,18 @@ export default {
|
|||
}
|
||||
},
|
||||
|
||||
watch: {
|
||||
'$route.path' () {
|
||||
// a hack method to get open web analytics working correctly
|
||||
// using plugin and any of the router guards always results in wrong page
|
||||
// being recorded
|
||||
if (window && window.owa_cmds) {
|
||||
window.owa_cmds.push(['trackPageView']);
|
||||
window.owa_cmds.push(['trackClicks']);
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
methods: {
|
||||
toggleMenu () {
|
||||
this.isMenuOpen = !this.isMenuOpen
|
||||
|
@ -37,6 +49,8 @@ export default {
|
|||
closeMenu () {
|
||||
this.isMenuOpen = false
|
||||
},
|
||||
updateAnalytics () {
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
|
@ -69,7 +69,7 @@ module.exports = {
|
|||
*/
|
||||
plugins: [
|
||||
{ src: '~/plugins/Vuelidate' },
|
||||
{ src: '~/plugins/owa.js', mode: 'client' }
|
||||
// { src: '~/plugins/owa.js', mode: 'client' }
|
||||
],
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue