diff --git a/layouts/404.html b/layouts/404.html
index abcafdf0..0c02ee87 100644
--- a/layouts/404.html
+++ b/layouts/404.html
@@ -5,7 +5,7 @@
@@ -29,7 +29,7 @@
{{ end }}
{{ end }}
- {{ if .Site.Params.section_pager }}
+ {{ if site.Params.section_pager }}
{{ partial "section_pager.html" . }}
diff --git a/layouts/index.json b/layouts/index.json
index 7dde82e0..a97f11f2 100644
--- a/layouts/index.json
+++ b/layouts/index.json
@@ -1,8 +1,8 @@
{{- /* Generate the search index. */ -}}
{{- $index := slice -}}
-{{- $pages := .Site.RegularPages -}}
+{{- $pages := site.RegularPages -}}
{{- /* Add the index page of docs separately since it's not in RegularPages above. */ -}}
-{{- $pages := $pages | union (where (where .Site.Pages "Kind" "section") "Type" "docs") -}}
+{{- $pages := $pages | union (where (where site.Pages "Kind" "section") "Type" "docs") -}}
{{- /* Add author pages to index so their bios can be searched. Hide empty `/author/` node. */ -}}
{{- $pages := $pages | union (where (where site.Pages "Section" "author") "Params.name" "!=" nil) -}}
diff --git a/layouts/partials/comments.html b/layouts/partials/comments.html
index e4a2eb90..977ec849 100644
--- a/layouts/partials/comments.html
+++ b/layouts/partials/comments.html
@@ -1,4 +1,4 @@
-{{ if and .Site.DisqusShortname (not (or .Site.Params.disable_comments .Params.disable_comments)) }}
+{{ if and site.DisqusShortname (not (or site.Params.disable_comments .Params.disable_comments)) }}
diff --git a/layouts/partials/cookie_consent.html b/layouts/partials/cookie_consent.html
index 015adb2a..9e7536a4 100644
--- a/layouts/partials/cookie_consent.html
+++ b/layouts/partials/cookie_consent.html
@@ -1,4 +1,4 @@
-{{ if .Site.Params.privacy_pack }}
+{{ if site.Params.privacy_pack }}
{{ $scr := .Scratch }}
@@ -20,7 +20,7 @@
"message": {{ i18n "cookie_message" | default "This website uses cookies to ensure you get the best experience on our website." }},
"dismiss": {{ i18n "cookie_dismiss" | default "Got it!" }},
"link": {{ i18n "cookie_learn" | default "Learn more" }},
- "href": {{ with .Site.GetPage "privacy.md" }}{{ printf "%s" .RelPermalink }}{{ else }}"https://cookies.insites.com"{{ end }}
+ "href": {{ with site.GetPage "privacy.md" }}{{ printf "%s" .RelPermalink }}{{ else }}"https://cookies.insites.com"{{ end }}
}
})});
diff --git a/layouts/partials/css/parse_theme.css b/layouts/partials/css/parse_theme.css
index cda684fe..904aff97 100644
--- a/layouts/partials/css/parse_theme.css
+++ b/layouts/partials/css/parse_theme.css
@@ -2,9 +2,9 @@
{{- $site := $scr.Get "site" -}}
{{/* Attempt to load font style specified by user. */}}
-{{- $font_index := .Site.Params.font | default "default" -}}
-{{ if isset .Site.Data.fonts $font_index }}
- {{- $font := index .Site.Data.fonts $font_index -}}
+{{- $font_index := site.Params.font | default "default" -}}
+{{ if isset site.Data.fonts $font_index }}
+ {{- $font := index site.Data.fonts $font_index -}}
{{- $scr.Set "google_fonts" $font.google_fonts -}}
{{- $scr.Set "body_font" $font.body_font -}}
{{- $scr.Set "heading_font" $font.heading_font -}}
@@ -15,9 +15,9 @@
{{ end }}
{{/* Attempt to load color theme specified by user. */}}
-{{- $theme_index := .Site.Params.color_theme | default "default" -}}
-{{ if isset .Site.Data.themes $theme_index }}
- {{ $theme := index .Site.Data.themes $theme_index }}
+{{- $theme_index := site.Params.color_theme | default "default" -}}
+{{ if isset site.Data.themes $theme_index }}
+ {{ $theme := index site.Data.themes $theme_index }}
{{- $scr.Set "light" $theme.light -}}
diff --git a/layouts/partials/docs_sidebar.html b/layouts/partials/docs_sidebar.html
index b293652f..4c617089 100644
--- a/layouts/partials/docs_sidebar.html
+++ b/layouts/partials/docs_sidebar.html
@@ -1,6 +1,6 @@
{{ $current_page := . }}
{{ $menu_name := (path.Base (path.Split .Path).Dir) }}
-{{ with (index .Site.Menus $menu_name) }}
+{{ with (index site.Menus $menu_name) }}
{{ else }}
{{ errorf "Please define menu items named `[menu.%s]` in your %s front matter or define `[[menu.%s]]` in `config.toml`." $menu_name .Path $menu_name }}
{{ end }}
@@ -16,7 +16,7 @@