summaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2021-11-24 13:01:07 +0100
committerTor Andersson <tor@ccxvii.net>2021-11-24 13:01:07 +0100
commitbae41289cf5c2043c9b1795ab6df34477538bcdd (patch)
tree6310aafd7db8b0f8ec8c12a55bdaac6a80194daf /views
parent255aa6f214f1005b671acf9c64d2beb13e0a7861 (diff)
downloadserver-bae41289cf5c2043c9b1795ab6df34477538bcdd.tar.gz
Preload web fonts to minimize flash of invisible text.
Diffstat (limited to 'views')
-rw-r--r--views/head.pug9
1 files changed, 8 insertions, 1 deletions
diff --git a/views/head.pug b/views/head.pug
index 2b7858e..0af064c 100644
--- a/views/head.pug
+++ b/views/head.pug
@@ -1,10 +1,17 @@
//- vim:ts=4:sw=4:
meta(name="viewport" content="width=device-width,height=device-height,initial-scale=1")
-link(rel="icon" href="/favicon.svg")
+link(rel="icon" type="image/svg+xml" href="/favicon.svg")
link(rel="stylesheet" href="/fonts/fonts.css")
link(rel="stylesheet" href="/style.css")
+link(rel="preload" as="font" type="font/woff2" crossorigin href="fonts/SourceSerif4-Regular.woff2")
+link(rel="preload" as="font" type="font/woff2" crossorigin href="fonts/SourceSerif4-Semibold.woff2")
+link(rel="preload" as="font" type="font/woff2" crossorigin href="fonts/SourceSerif4-It.woff2")
+link(rel="preload" as="font" type="font/woff2" crossorigin href="fonts/SourceSans3-Regular.woff2")
+link(rel="preload" as="font" type="font/woff2" crossorigin href="fonts/Dingbats.woff2")
+link(rel="preload" as="font" type="font/woff2" crossorigin href="fonts/NotoEmoji.woff2")
+
mixin forumpost(row,show_buttons)
.post
.head