Skip to content

Commit

Permalink
defer google analytic
Browse files Browse the repository at this point in the history
  • Loading branch information
maxence-charriere committed Oct 2, 2024
1 parent 2b4f798 commit f5f2689
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/analytics/google-analytics.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
// field to initialize Google Analytics.
func GoogleAnalyticsHeader(propertyID string) string {
return fmt.Sprintf(`<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=%s"></script>
<script defer src="https://www.googletagmanager.com/gtag/js?id=%s"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
Expand Down

0 comments on commit f5f2689

Please sign in to comment.