diff options
Diffstat (limited to 'layouts/partials/head/headscript.html')
| -rw-r--r-- | layouts/partials/head/headscript.html | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/layouts/partials/head/headscript.html b/layouts/partials/head/headscript.html new file mode 100644 index 00000000..8ed6fd40 --- /dev/null +++ b/layouts/partials/head/headscript.html @@ -0,0 +1,24 @@ +<!-- Global JavaScript Variables --> +<script> + var waline_options = { + // basic configuration + el: '#waline', + serverURL: 'https://waline.geedea.pro', + dark: 'auto', + search: false, + // if localhost then disable pageview count + pageview: (location.href.includes('localhost')) ? false : true + }; +</script> + +<script> +/* === umami tracking === */ +if (window.location.hostname !== 'localhost') { + // track traffic + const script = document.createElement('script'); + script.defer = true; + script.src = 'https://cloud.umami.is/script.js'; + script.dataset.websiteId = 'ae8c2619-56eb-4577-ac31-9dc6ea44bda7'; + document.head.appendChild(script); +} +</script> |
