see if gtm automatically pushes pageview events without our own page-tracking code

This commit is contained in:
Neil Lalonde 2016-09-01 12:16:54 -04:00
parent 929730c008
commit 572713b801
1 changed files with 0 additions and 13 deletions

View File

@ -33,18 +33,5 @@ export default {
window.ga('send', 'pageview', {page: url, title: title});
});
}
// And Google Tag Manager too
if (typeof window.dataLayer !== 'undefined') {
onPageChange((url, title) => {
window.dataLayer.push({
'event': 'virtualPageView',
'page': {
'title': title,
'url': url
}
});
});
}
}
};