font: use font-display:fallback

Provides a more stable experience than `optional`, as it doesn't let the
browser decide whether or not to apply the font.

Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
This commit is contained in:
David Karlsson 2024-01-25 14:48:43 +01:00
parent d8a5a60327
commit 1ed2721b40
1 changed files with 2 additions and 2 deletions

View File

@ -37,8 +37,8 @@
</script>
{{ end }}
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:400,500&display=optional" />
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Roboto+Mono&display=optional" />
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:400,500&display=fallback" />
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Roboto+Mono&display=fallback" />
{{ partial "utils/css.html" . }}
{{ $theme := resources.Get "js/theme.js" | js.Build (dict "minify" true) }}
<script>{{ $theme.Content | safeJS }}</script>