From 5b9e9c94bf5b0694516ae9c2b68025f1eec00a0b Mon Sep 17 00:00:00 2001 From: XhmikosR Date: Sat, 30 Mar 2024 18:53:09 +0200 Subject: [PATCH 1/2] Move JavaScript to head We use defer for all JS so the requests are not blocking --- src/layouts/_default/baseof.html | 1 - src/layouts/partials/head.html | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/src/layouts/_default/baseof.html b/src/layouts/_default/baseof.html index 53189319e..43f338ab2 100644 --- a/src/layouts/_default/baseof.html +++ b/src/layouts/_default/baseof.html @@ -20,6 +20,5 @@ {{ partial "footer" . }} - {{ partial "scripts" . }} diff --git a/src/layouts/partials/head.html b/src/layouts/partials/head.html index b1b5f1713..9bd3036b0 100644 --- a/src/layouts/partials/head.html +++ b/src/layouts/partials/head.html @@ -24,4 +24,5 @@ {{ partial "stylesheet" . -}} {{ partial "favicons" . -}} {{ partial "social" . -}} +{{ partial "scripts" . -}} {{ partial "analytics" . -}} From 201e2a91d063755f9174bab56e31ac95f6623938 Mon Sep 17 00:00:00 2001 From: XhmikosR Date: Sat, 30 Mar 2024 22:04:29 +0200 Subject: [PATCH 2/2] Update head.html --- src/layouts/partials/head.html | 1 + 1 file changed, 1 insertion(+) diff --git a/src/layouts/partials/head.html b/src/layouts/partials/head.html index 31ce3eb3c..fba3cb9ac 100644 --- a/src/layouts/partials/head.html +++ b/src/layouts/partials/head.html @@ -24,6 +24,7 @@ {{ partial "stylesheet" . -}} {{ partial "favicons" . -}} {{ partial "social" . -}} +{{ partial "scripts" . -}} {{- if hugo.IsProduction }} {{ partial "analytics" . -}} {{- end }}