remove google analytics in favor of fathom

This commit is contained in:
wgroeneveld 2020-05-26 17:26:17 +02:00
parent e739f4228d
commit 7875f82c60
2 changed files with 17 additions and 3 deletions

View File

@ -2,8 +2,6 @@ baseurl = "https://jefklakscodex.com/"
title = "Jefklaks Codex"
theme = "jefklak-creative-portfolio"
languageCode = "en-us"
disqusShortname = ""
googleAnalytics = "UA-122825031-1"
publishDir = "docs"
enableEmoji = true
# for .Lastmod to work with .GitInfo: --enableGitInfo https://gohugo.io/variables/git/
@ -19,6 +17,8 @@ summaryLength = 20
defaultMarkdownHandler = "blackfriday"
[params]
fathomid = "YFJHP"
font = "PT Sans"
description = "Retro game thoughts"
copyright = "No &copy; reserved - sharing is caring. <a href='https://github.com/wgroeneveld/jefklakscodex' target='_blank'>Hack away!</a><br/>An integral part of <a href='https://brainbaking.com/' target='_blank'>Brain Baking</a>."

View File

@ -107,5 +107,19 @@ body, .content-column-content, h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5,
<link href="{{ .RelPermalink }}" rel="feed" type="application/rss+xml" title="Jefklak's Codex" />
{{ end }}
{{- if (ne hugo.Environment "development") }}
{{ template "_internal/google_analytics.html" . }}
<!-- Fathom - simple website analytics - https://github.com/usefathom/fathom -->
<script>
(function(f, a, t, h, o, m){
a[h]=a[h]||function(){
(a[h].q=a[h].q||[]).push(arguments)
};
o=f.createElement('script'),
m=f.getElementsByTagName('script')[0];
o.async=1; o.src=t; o.id='fathom-script';
m.parentNode.insertBefore(o,m)
})(document, window, '//fathom.brainbaking.com/tracker.js', 'fathom');
fathom('set', 'siteId', '{{ .Site.Params.fathomid }}');
fathom('trackPageview');
</script>
<!-- / Fathom -->
{{- end }}