Add self-hosted goat counter

This commit is contained in:
SilverLuke 2023-10-29 11:09:30 +01:00
parent fbbef3b2c5
commit 761a14d2e9

View file

@ -1,6 +1,6 @@
<!-- Add Analytics if enabled in configuration --> <!-- Add Analytics if enabled in configuration -->
{{ with site.Params.features.analytics }} {{ with site.Params.features.analytics }}
{{ if .enabled }} {{ if .enable }}
{{ with .services }} {{ with .services }}
<!-- Google Analytics --> <!-- Google Analytics -->
{{ with .google }} {{ with .google }}
@ -19,11 +19,11 @@
<!-- GoatCounter --> <!-- GoatCounter -->
{{ with .goatCounter }} {{ with .goatCounter }}
<script {{ if .selfHosted }}
data-goatcounter="https://{{ .code }}.goatcounter.com/count" <script data-goatcounter="https://{{ .url }}/count" async src="https://{{ .url }}/count.js"></script>
async {{ else }}
src="//gc.zgo.at/count.js" <script data-goatcounter="https://{{ .code }}.goatcounter.com/count" async src="//gc.zgo.at/count.js"></script>
></script> {{ end }}
{{ end }} {{ end }}
<!-- Piwik/Matomo --> <!-- Piwik/Matomo -->