Skip to content

Commit

Permalink
Merge pull request #71 from quid/perf/reduce-time-to-first-render
Browse files Browse the repository at this point in the history
perf: reduce time to first render with font-display: swap
  • Loading branch information
FezVrasta authored Mar 21, 2019
2 parents 9774f2e + e7f036e commit f394f2c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/theme/fonts/ibmplex/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
font-family: 'IBM Plex Sans';
font-weight: 400;
font-style: normal;
font-display: swap;
src: url('ibmplexsans-regular-webfont.woff2') format('woff2'),
url('ibmplexsans-regular-webfont.woff') format('woff');
}
Expand All @@ -10,6 +11,7 @@
font-family: 'IBM Plex Sans';
font-weight: 400;
font-style: italic;
font-display: swap;
src: url('ibmplexsans-italic-webfont.woff2') format('woff2'),
url('ibmplexsans-italic-webfont.woff') format('woff');
}
Expand All @@ -18,6 +20,7 @@
font-family: 'IBM Plex Sans';
font-weight: 700;
font-style: normal;
font-display: swap;
src: url('ibmplexsans-semibold-webfont.woff2') format('woff2'),
url('ibmplexsans-semibold-webfont.woff') format('woff');
}
Expand All @@ -26,6 +29,7 @@
font-family: 'IBM Plex Sans';
font-weight: 700;
font-style: italic;
font-display: swap;
src: url('ibmplexsans-semibolditalic-webfont.woff2') format('woff2'),
url('ibmplexsans-semibolditalic-webfont.woff') format('woff');
}
Expand All @@ -34,6 +38,7 @@
font-family: 'IBM Plex Serif';
font-weight: 400;
font-style: normal;
font-display: swap;
src: url('ibmplexserif-regular-webfont.woff2') format('woff2'),
url('ibmplexserif-regular-webfont.woff') format('woff');
}
Expand All @@ -42,6 +47,7 @@
font-family: 'IBM Plex Serif';
font-weight: 400;
font-style: italic;
font-display: swap;
src: url('ibmplexserif-italic-webfont.woff2') format('woff2'),
url('ibmplexserif-italic-webfont.woff') format('woff');
}
Expand All @@ -50,6 +56,7 @@
font-family: 'IBM Plex Serif';
font-weight: 700;
font-style: normal;
font-display: swap;
src: url('ibmplexserif-semibold-webfont.woff2') format('woff2'),
url('ibmplexserif-semibold-webfont.woff') format('woff');
}
Expand All @@ -58,6 +65,7 @@
font-family: 'IBM Plex Serif';
font-weight: 700;
font-style: italic;
font-display: swap;
src: url('ibmplexserif-semibolditalic-webfont.woff2') format('woff2'),
url('ibmplexserif-semibolditalic-webfont.woff') format('woff');
}
1 change: 1 addition & 0 deletions packages/theme/fonts/icons/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@
url('quid-icons.svg#quid-icons') format('svg');
font-weight: normal;
font-style: normal;
font-display: swap;
}

0 comments on commit f394f2c

Please sign in to comment.