Learn business growth with Google Analytics 4 › Forums › Google Analytics 4 › Troubleshooting Shopify theme's failure to fire Google Analytics 4 ecommerce events › Reply To: Troubleshooting Shopify theme's failure to fire Google Analytics 4 ecommerce events
-
Hey, so looking at your code I spotted this bit:
dataLayer.push({ ecommerce: null });
The issue here is that the word “null” is actually making the
dataLayer
not work. Think of “null” like a giant off switch. By including it, you’re essentially pressing pause on all thingsdataLayer
. What you should do is take out that line and it should be functioning properly then.