holidaycheck / react-google-tag-manager

This repository contains a react based implementation for Google's Tag Manager snippet.
MIT License
192 stars 31 forks source link

Place dataLayer befor gtm.js event #64

Open mhryshchenko opened 7 years ago

mhryshchenko commented 7 years ago

Hello, due to google spec dataLayer array should be placed above the snippet itself, is there any way to do it with you lib?

qoute: "Note: If you put the Google Tag Manager container snippet above the dataLayer array, Google Tag Manager may malfunction, and will not be able to read the variables defined in the array."