Skip to content

Commit 184ee25

Browse files
ldezimfing
andauthored
fix(analytics): Matomo analytics (#817)
* fix: Matomo analytics * chore: use with * Revert "chore: use with" This reverts commit 1d86e6f. --------- Co-authored-by: Xin <[email protected]>
1 parent cc5884d commit 184ee25

File tree

2 files changed

+14
-2
lines changed

2 files changed

+14
-2
lines changed

layouts/_partials/components/analytics/matomo.html

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,16 @@
33
https://developer.matomo.org/guides/tracking-javascript-guide
44
*/ -}}
55

6+
{{- with .Site.Params.analytics.matomo -}}
7+
8+
{{- if not .serverURL }}
9+
{{- errorf "Missing Matomo 'serverURL' configuration. See https://imfing.github.io/hextra/versions/latest/docs/guide/configuration/#matomo-analytics" -}}
10+
{{- end -}}
11+
12+
{{- if not .websiteID }}
13+
{{- errorf "Missing Matomo 'websiteID' configuration. See https://imfing.github.io/hextra/versions/latest/docs/guide/configuration/#matomo-analytics" -}}
14+
{{- end -}}
15+
616
<!-- Matomo -->
717
<script type="text/javascript">
818
var _paq = window._paq = window._paq || [];
@@ -17,3 +27,5 @@
1727
})();
1828
</script>
1929
<!-- End Matomo Code -->
30+
31+
{{- end -}}

layouts/_partials/components/analytics/umami.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@
66
{{- with .Site.Params.analytics.umami -}}
77

88
{{- if not .serverURL }}
9-
{{- errorf "Missing Umami 'serverURL' configuration. See TODO" -}}
9+
{{- errorf "Missing Umami 'serverURL' configuration. See https://imfing.github.io/hextra/versions/latest/docs/guide/configuration/#umami-analytics" -}}
1010
{{- end -}}
1111

1212
{{- if not .websiteID }}
13-
{{- errorf "Missing Umami 'websiteID' configuration. See TODO" -}}
13+
{{- errorf "Missing Umami 'websiteID' configuration. See https://imfing.github.io/hextra/versions/latest/docs/guide/configuration/#umami-analytics" -}}
1414
{{- end -}}
1515

1616
{{- $attributes := newScratch -}}

0 commit comments

Comments
 (0)