From 98187f7d0dd02b8f5bf36f902babc4772d2da3da Mon Sep 17 00:00:00 2001 From: Josh Worden Date: Fri, 2 Apr 2021 10:17:27 -0500 Subject: [PATCH] =?UTF-8?q?Don=E2=80=99t=20pass=20in=20the=20window=20glob?= =?UTF-8?q?al?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/marko-web-native-x/utils/gtm-events.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/packages/marko-web-native-x/utils/gtm-events.js b/packages/marko-web-native-x/utils/gtm-events.js index c523d4835..8d3f605bd 100644 --- a/packages/marko-web-native-x/utils/gtm-events.js +++ b/packages/marko-web-native-x/utils/gtm-events.js @@ -1,19 +1,20 @@ -export const pageLoad = (window) => { +/* eslint-disable no-undef */ +export const pageLoad = () => { const dataLayer = window.dataLayerNativeX; if (dataLayer) dataLayer.push({ event: 'page_load' }); }; -export const outboundLink = (window, url) => { +export const outboundLink = (url) => { const dataLayer = window.dataLayerNativeX; if (dataLayer) dataLayer.push({ event: 'outbound_click', outbound_url: url, eventTimeout: 3000 }); }; -export const share = (window, provider) => { +export const share = (provider) => { const dataLayer = window.dataLayerNativeX; if (dataLayer) dataLayer.push({ event: 'share', social_provider: provider }); }; -export const endOfContent = (window) => { +export const endOfContent = () => { const dataLayer = window.dataLayerNativeX; if (dataLayer) dataLayer.push({ event: 'scroll_to_bottom' }); };