Skip to content

Commit

Permalink
Merge pull request #19 from skipgu/resolve-g-analytics-error
Browse files Browse the repository at this point in the history
Override Google Analytics synchronization mechanism
  • Loading branch information
michalspano committed Nov 14, 2023
2 parents 1f7f23a + b006b8c commit 59f0466
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ email: skip@gota.gu.se
instagram_username: "skip.gu"
linkedin_username: "company/skip-student-association"
discord_link: "https://tinyurl.com/skip-discord"
google_analytics: G-96M5M9TCM7
# google_analytics: G-96M5M9TCM7
12 changes: 12 additions & 0 deletions _includes/google-analytics.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-96M5M9TCM7"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
// The value is parsed 'raw' like this, because it's part of the URL above anyway.
// Therefore, the value from _config.yml need not to be used.
gtag('config', 'G-96M5M9TCM7');
</script>


0 comments on commit 59f0466

Please sign in to comment.