From 351e4b5092294cabf7822f7363911ef3fe8b17c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Thibaud?= Date: Mon, 3 Jan 2022 10:13:43 +0100 Subject: [PATCH] fix (performance) : add two rules in font face declare --- src/scss/abstract/_m-declare-font-face.scss | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/scss/abstract/_m-declare-font-face.scss b/src/scss/abstract/_m-declare-font-face.scss index 9e67971a..c5c6ffcd 100644 --- a/src/scss/abstract/_m-declare-font-face.scss +++ b/src/scss/abstract/_m-declare-font-face.scss @@ -11,9 +11,12 @@ font-style: $font-style; font-weight: $font-weight; font-stretch: $font-stretch; - font-display: swap; src: + local("#{$font-family}"), /* search for the locally installed font first */ url(#{$font-filename}.woff2) format("woff2"), url(#{$font-filename}.woff) format("woff"); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */ + + font-display: swap; + unicode-range: U+0-10FFFF; /* cutting of the font file for better loading */ } }