Skip to content

Commit 3688015

Browse files
committed
Add Google Analytics 4 tracking (GA4)
- Inject gtag.js snippet before </head> for SEO monitoring - Measurement ID: G-XXXXXXXXXX (placeholder — replace with real ID)
1 parent a178a99 commit 3688015

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

docs/site/index.html

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,14 @@
4949
</script>
5050

5151
<link rel="stylesheet" href="style.css">
52+
<!-- Google Analytics 4 -->
53+
<script async src="https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXXXX"></script>
54+
<script>
55+
window.dataLayer = window.dataLayer || [];
56+
function gtag(){dataLayer.push(arguments);}
57+
gtag('js', new Date());
58+
gtag('config', 'G-XXXXXXXXXX');
59+
</script>
5260
</head>
5361
<body>
5462

0 commit comments

Comments
 (0)