Skip to content

Commit 07daf89

Browse files
authored
Merge pull request #203 from BeAPI/fix/fonts-loading-performance
fix (performance) : add two rules in font face declare
2 parents 86a5f0d + 351e4b5 commit 07daf89

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/scss/abstract/_m-declare-font-face.scss

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,12 @@
1111
font-style: $font-style;
1212
font-weight: $font-weight;
1313
font-stretch: $font-stretch;
14-
font-display: swap;
1514
src:
15+
local("#{$font-family}"), /* search for the locally installed font first */
1616
url(#{$font-filename}.woff2) format("woff2"),
1717
url(#{$font-filename}.woff) format("woff"); /* Chrome 6+, Firefox 3.6+, IE 9+, Safari 5.1+ */
18+
19+
font-display: swap;
20+
unicode-range: U+0-10FFFF; /* cutting of the font file for better loading */
1821
}
1922
}

0 commit comments

Comments
 (0)