From 6ee1cf689233fc37ed246e3ed6afc2233ab0885d Mon Sep 17 00:00:00 2001 From: Djordje Atlialp Date: Thu, 16 Apr 2020 08:35:22 +0200 Subject: [PATCH] Use hugo template for google analytics https://gohugo.io/templates/internal/#use-the-google-analytics-template --- layouts/partials/javascript.html | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/layouts/partials/javascript.html b/layouts/partials/javascript.html index 7cff6d1..02bdd8d 100644 --- a/layouts/partials/javascript.html +++ b/layouts/partials/javascript.html @@ -6,18 +6,11 @@ {{- if .Site.GoogleAnalytics }} - + {{ template "_internal/google_analytics.html" . }} {{- end}} {{ range $val := $.Site.Params.customJS }} - {{ if gt (len $val) 0 }} - - {{ end }} + {{ if gt (len $val) 0 }} + + {{ end }} {{ end }}