@blotoutio/providers-google-analytics-4-sdk
Advanced tools
Comparing version 0.10.6 to 0.10.7
11
index.js
@@ -138,3 +138,3 @@ var ProvidersGoogleAnalytics4Sdk = (function () { | ||
}; | ||
const handleTag = ({ data = {}, eventName, eventId, }) => { | ||
const handleTag = ({ data = {}, eventName, eventId, manifestVariables, }) => { | ||
if (!eventName || !window.gtag) { | ||
@@ -144,2 +144,5 @@ return; | ||
const { event, eventData } = getEvent(eventName, data, eventId); | ||
if (manifestVariables && manifestVariables['measurementId']) { | ||
eventData['send_to'] = manifestVariables['measurementId']; | ||
} | ||
window.gtag('event', event, eventData); | ||
@@ -172,10 +175,10 @@ }; | ||
const tag = ({ data, eventName }) => { | ||
const tag = ({ data, eventName, manifestVariables, eventId }) => { | ||
const isLoaded = window && window.gtag && !!getCookieValue('_ga'); | ||
if (isLoaded) { | ||
handleTag({ data, eventName }); | ||
handleTag({ data, eventName, manifestVariables, eventId }); | ||
} | ||
return { | ||
loaded: isLoaded, | ||
sdkVersion: "0.10.6" , | ||
sdkVersion: "0.10.7" , | ||
}; | ||
@@ -182,0 +185,0 @@ }; |
{ | ||
"name": "@blotoutio/providers-google-analytics-4-sdk", | ||
"version": "0.10.6", | ||
"version": "0.10.7", | ||
"description": "Google Analytics 4 Browser SDK for EdgeTag", | ||
@@ -5,0 +5,0 @@ "author": "Blotout", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7042
196