From e86c7592fc75ce3b14296b060688abc799bfac42 Mon Sep 17 00:00:00 2001 From: Julian Alarcon Date: Thu, 4 Feb 2021 11:30:10 -0500 Subject: [PATCH] Added Google Analytics feature --- exampleSite/config.yaml | 1 + layouts/partials/head/head.html | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index fb89f51..e005c22 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -6,6 +6,7 @@ title: Example Site # Change it to your Disqus shortname before using disqusShortname: hugo-theme-stack +googleAnalytics: "UI-you-google-analytics-tracking-id" # Theme i18n support # Available values: en, fr, id, ja, ko, pt-br, zh-cn diff --git a/layouts/partials/head/head.html b/layouts/partials/head/head.html index de2982c..b858021 100644 --- a/layouts/partials/head/head.html +++ b/layouts/partials/head/head.html @@ -21,4 +21,5 @@ {{ end }} -{{- partial "head/custom.html" . -}} \ No newline at end of file +{{- partial "head/custom.html" . -}} +{{ template "_internal/google_analytics_async.html" . }} \ No newline at end of file