fix: preload Google Fonts to reduce layout shift (#1215)
* fix: preload Google Fonts to reduce layout shift Move font loading from footer JS to head with preconnect and preload hints. This reduces CLS by ensuring fonts load earlier in the page lifecycle instead of being dynamically inserted after footer loads. * style: reorder custom font inclusion in head template --------- Co-authored-by: delize <4028612+delize@users.noreply.github.com> Co-authored-by: Jimmy Cai <jimmy@cai.im>
This commit is contained in:
co-authored by
delize
Jimmy Cai
parent
bc1b55e60a
commit
0cefe05973
@@ -10,6 +10,7 @@
|
||||
|
||||
<link rel='canonical' href='{{ .Permalink }}'>
|
||||
|
||||
{{- partial "head/custom-font.html" . -}}
|
||||
{{- partial "head/style.html" . -}}
|
||||
{{- partial "head/script.html" . -}}
|
||||
{{- partial "head/opengraph/include.html" . -}}
|
||||
|
||||
Reference in New Issue
Block a user