Skip to content

Commit

Permalink
feat: Uses google analytics only when not on development
Browse files Browse the repository at this point in the history
  • Loading branch information
o-leolleo committed Dec 10, 2023
1 parent ce0f197 commit d13544c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion layouts/_default/baseof.html
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
<title>{{ .Page.Title }}</title>
</head>

{{ if .Site.Params.GoogleAnalyticsTag }}
{{ if and (not .Site.IsServer) .Site.Params.GoogleAnalyticsTag }}
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id={{ .Site.Params.GoogleAnalyticsTag }}"></script>
<script>
Expand Down

0 comments on commit d13544c

Please sign in to comment.