From 82a8b2f8c6a94e76d395a8c70998ef24838e32c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6ren=20Weber?= Date: Sat, 12 Nov 2022 15:16:53 +0100 Subject: [PATCH] theme: cache calls to fileExists #380 --- layouts/404.html | 2 +- layouts/partials/archetype.hugo | 3 ++- layouts/partials/fileExists.hugo | 1 + layouts/partials/header.html | 2 +- layouts/partials/output-partial.hugo | 6 ++++-- layouts/partials/search.html | 4 ++-- layouts/partials/stylesheet.html | 3 ++- 7 files changed, 13 insertions(+), 8 deletions(-) create mode 100644 layouts/partials/fileExists.hugo diff --git a/layouts/404.html b/layouts/404.html index 6a8371c5cc..050950a38d 100644 --- a/layouts/404.html +++ b/layouts/404.html @@ -11,7 +11,7 @@ {{- end }} {{ .Scratch.Get "title" }} {{ default "::" .Site.Params.titleSeparator }} {{ .Site.Title }} - {{- partial "favicon.html" . }} + {{- partialCached "favicon.html" . }} {{- partial "stylesheet.html" . }}