diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 11fb6788..8f17b936 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -18,7 +18,7 @@ {{- block "main" . }} {{- end }} - {{- partialCached "footer.html" . .Type .Layout }} + {{- partialCached "footer.html" . .Type .Layout .Params }} diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index c384c4ed..b34d278a 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -18,7 +18,8 @@ {{- partial "extend_footer.html" . -}} -{{ if (and (in site.Params.mainSections .Type) (ne .Layout `archives`) (ne .Layout `search`)) }} +{{- $isHLJSdisabled := (.Site.Params.assets.disableHLJS | default .Params.disableHLJS ) }} +{{- if (and (in site.Params.mainSections .Type) (ne .Layout `archives`) (ne .Layout `search`) (not $isHLJSdisabled)) }} {{- if not .Site.Params.assets.disableFingerprinting }} {{- $highlight := slice (resources.Get "js/highlight.min.js") | resources.Concat "assets/js/highlight.js" | minify | fingerprint }}