diff --git a/README.md b/README.md index 7cefd74..fd233dc 100644 --- a/README.md +++ b/README.md @@ -46,8 +46,11 @@ baseurl = "https://example.com/" title = "SiteTitle" theme = "hugo_theme_robust" -googleAnalytics = "UA-XXXXXXXX-XX" # Optional -disqusShortname = "XYW" +[services] + [services.disqus] + shortname = '' + [services.googleAnalytics] + id = 'UA-XXXXXXXX-XX' # Optical [params] description = "This is site description" diff --git a/layouts/_default/baseof.amp.html b/layouts/_default/baseof.amp.html index 61071da..f1d7654 100644 --- a/layouts/_default/baseof.amp.html +++ b/layouts/_default/baseof.amp.html @@ -7,7 +7,7 @@ {{ partial "meta.html" . }} {{ block "meta" . }}{{ end }} - {{ if and .Site.GoogleAnalytics (ne (getenv "HUGO_ENV") "DEV") }} + {{ if and .Site.Config.Services.GoogleAnalytics.ID (ne (getenv "HUGO_ENV") "DEV") }} {{ end }} @@ -45,14 +45,14 @@ - {{ if and .Site.GoogleAnalytics (ne (getenv "HUGO_ENV") "DEV") }} + {{ if and .Site.Config.Services.GoogleAnalytics.ID (ne (getenv "HUGO_ENV") "DEV") }} + {{ end }}