mirror of
https://github.com/imfing/hextra.git
synced 2025-09-14 05:17:08 -04:00
fix(analytics): Matomo analytics (#817)
* fix: Matomo analytics
* chore: use with
* Revert "chore: use with"
This reverts commit 1d86e6fa0f
.
---------
Co-authored-by: Xin <xin@imfing.com>
This commit is contained in:

committed by
GitHub

parent
cc5884dd2a
commit
184ee25011
@@ -3,6 +3,16 @@ Matomo Analytics.
|
|||||||
https://developer.matomo.org/guides/tracking-javascript-guide
|
https://developer.matomo.org/guides/tracking-javascript-guide
|
||||||
*/ -}}
|
*/ -}}
|
||||||
|
|
||||||
|
{{- with .Site.Params.analytics.matomo -}}
|
||||||
|
|
||||||
|
{{- if not .serverURL }}
|
||||||
|
{{- errorf "Missing Matomo 'serverURL' configuration. See https://imfing.github.io/hextra/versions/latest/docs/guide/configuration/#matomo-analytics" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{- if not .websiteID }}
|
||||||
|
{{- errorf "Missing Matomo 'websiteID' configuration. See https://imfing.github.io/hextra/versions/latest/docs/guide/configuration/#matomo-analytics" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
<!-- Matomo -->
|
<!-- Matomo -->
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
var _paq = window._paq = window._paq || [];
|
var _paq = window._paq = window._paq || [];
|
||||||
@@ -17,3 +27,5 @@ https://developer.matomo.org/guides/tracking-javascript-guide
|
|||||||
})();
|
})();
|
||||||
</script>
|
</script>
|
||||||
<!-- End Matomo Code -->
|
<!-- End Matomo Code -->
|
||||||
|
|
||||||
|
{{- end -}}
|
||||||
|
@@ -6,11 +6,11 @@ https://umami.is/docs/tracker-configuration
|
|||||||
{{- with .Site.Params.analytics.umami -}}
|
{{- with .Site.Params.analytics.umami -}}
|
||||||
|
|
||||||
{{- if not .serverURL }}
|
{{- if not .serverURL }}
|
||||||
{{- errorf "Missing Umami 'serverURL' configuration. See TODO" -}}
|
{{- errorf "Missing Umami 'serverURL' configuration. See https://imfing.github.io/hextra/versions/latest/docs/guide/configuration/#umami-analytics" -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
{{- if not .websiteID }}
|
{{- if not .websiteID }}
|
||||||
{{- errorf "Missing Umami 'websiteID' configuration. See TODO" -}}
|
{{- errorf "Missing Umami 'websiteID' configuration. See https://imfing.github.io/hextra/versions/latest/docs/guide/configuration/#umami-analytics" -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
{{- $attributes := newScratch -}}
|
{{- $attributes := newScratch -}}
|
||||||
|
Reference in New Issue
Block a user