You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently we are using ga4 with party town , user_enagament and scroll events are not working . below is the code which we are using . please suggest if anythings is missing.
forward: ['dataLayer.push','gtag','gtm.push'] and using a reverse proxy too. and tried using
resolveSendBeaconRequestParameters: function (url, location) {
if (url.hostname.includes('google-analytics') || url.pathname.includes('collect')) {
return {keepalive: false};
}
Describe the bug
Currently we are using ga4 with party town , user_enagament and scroll events are not working . below is the code which we are using . please suggest if anythings is missing.
forward: ['dataLayer.push','gtag','gtm.push'] and using a reverse proxy too. and tried using
resolveSendBeaconRequestParameters: function (url, location) {
<script type="text/partytown" nonce="script-GA-87a04770e6"> (function (window, document) { window.global = document; window.dataLayer = window.dataLayer || []; window.dataLayer.push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); window.gtag = function () { dataLayer.push(arguments); }; window.gtag('js', new Date()); window.gtag('config', 'G-xxxxxx'); var firstScript = document.getElementsByTagName('script')[0]; var gtmScript = document.createElement('script'); gtmScript.async = true; gtmScript.src = 'https://www.googletagmanager.com/gtag/js?id=G-xxxxxxx'; firstScript.parentNode.insertBefore(gtmScript, firstScript); })(window, document); </script>if (url.hostname.includes('google-analytics') || url.pathname.includes('collect')) {
return {keepalive: false};
}
Reproduction
https://www.stylecraze.com/performance-test/ga-debug.html
Steps to reproduce
When uservisted one page and spent more than 2 seconds then again he visited the other page then user_engagement should fire . but it's not happening.
Browser Info
all
Additional Information
No response
The text was updated successfully, but these errors were encountered: