From 4476a312b16d7d8c0bcfb08a1a986f78b98614b7 Mon Sep 17 00:00:00 2001 From: Habib Deriv <88178645+habib-deriv@users.noreply.github.com> Date: Mon, 27 Nov 2023 16:12:19 +0600 Subject: [PATCH] Revert "Fix gtm partytown integration (#6038)" (#6049) This reverts commit 442a6e85f3fcd5102a0ea36a62627a1545e19ae9. --- gatsby-config.js | 3 +++ gatsby-ssr.js | 33 ++++++++++++--------------------- 2 files changed, 15 insertions(+), 21 deletions(-) diff --git a/gatsby-config.js b/gatsby-config.js index 66d97899414..27319ae5805 100644 --- a/gatsby-config.js +++ b/gatsby-config.js @@ -48,6 +48,9 @@ module.exports = { `https://assets.customer.io/assets/track.js`, `https://static.deriv.com/scripts/cookie.js`, `https://widget.trustpilot.com/bootstrap/v5/tp.widget.bootstrap.min.js`, + `https://cdn.livechatinc.com/tracking.js`, + `https://www.google-analytics.com/analytics.js`, + `https://www.googletagmanager.com/gtm.js?id=${process.env.GATSBY_GOOGLE_TAG_MANAGER_TRACKING_ID}`, ], plugins: [ // [TODO] Enable this when we have a proper setup to enable caching, Otherwise it will cause one of them stop working. diff --git a/gatsby-ssr.js b/gatsby-ssr.js index 7048a3cbbb8..3d824a61786 100644 --- a/gatsby-ssr.js +++ b/gatsby-ssr.js @@ -14,38 +14,29 @@ export const onRenderBody = ({ setHeadComponents }) => { const gtmTrackingId = process.env.GATSBY_GOOGLE_TAG_MANAGER_TRACKING_ID || '' setHeadComponents([ - // Partytown setup , - ), - gtmTrackingId && ( -