Preload font and add font-display: swap; to increase loading speed

This commit is contained in:
schlagmichdoch 2023-12-13 17:20:46 +01:00
parent 77f2866893
commit b084a9b83b
2 changed files with 2 additions and 0 deletions

View file

@ -35,6 +35,7 @@
<meta property="og:image" content="images/logo_transparent_512x512.png">
<!-- Resources -->
<link rel="preload" href="lang/en.json" as="fetch">
<link rel="preload" href="fonts/OpenSans/static/OpenSans-Medium.ttf" as="font" type="font/ttf" crossorigin>
<link rel="stylesheet" type="text/css" href="styles/styles-main.css">
<link rel="manifest" href="manifest.json">
</head>

View file

@ -252,6 +252,7 @@ html[dir="rtl"] #expand.flipped > .icon {
@font-face {
font-family: "Open Sans";
src: url('../fonts/OpenSans/static/OpenSans-Medium.ttf') format('truetype');
font-display: swap;
}
body {