Skip to content

Commit

Permalink
try google analytics again 2
Browse files Browse the repository at this point in the history
  • Loading branch information
galtay committed Jan 6, 2025
1 parent 01d62fe commit e682666
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
6 changes: 2 additions & 4 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,6 @@ tag_archive:
enable_copy_code_button: true

analytics:
provider: "google-gtag"
google:
tracking_id: G-ZEN3CM576G
anonymize_ip: true
provider: "custom"


9 changes: 9 additions & 0 deletions _includes/analytics-providers/custom.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-ZEN3CM576G"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());

gtag('config', 'G-ZEN3CM576G');
</script>

0 comments on commit e682666

Please sign in to comment.