Skip to content

Instantly share code, notes, and snippets.

@thisismydesign
Created August 15, 2022 09:03
Show Gist options
  • Save thisismydesign/8486bb26a1c5c7627359d5fafeb52bb2 to your computer and use it in GitHub Desktop.
Save thisismydesign/8486bb26a1c5c7627359d5fafeb52bb2 to your computer and use it in GitHub Desktop.
The ultimate guide to Google Analytics /1
<!DOCTYPE html>
<html lang="en">
<head>
<!-- ... -->
<script
async
src="https://www.googletagmanager.com/gtag/js?id=G-xxxxxxxxxx" >
</script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-xxxxxxxxxx')
</script>
<!-- ... -->
</head>
<body>
<!-- ... -->
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment