Sometimes, we want to fix the failure to decode downloaded font with CSS.
In this article, we’ll look at how to fix the failure to decode downloaded font with CSS.
How to fix the failure to decode downloaded font with CSS?
To fix the failure to decode downloaded font with CSS, we fix the URL to the font.
For instance, we write
@font-face {
font-family: "MyWebFont";
src: url("webfont.eot");
src: url("webfont.eot?#iefix") format("embedded-opentype"),
url("webfont.woff2") format("woff2"), url("webfont.woff") format("woff"),
url("webfont.ttf") format("truetype"),
url("webfont.svg#svgFontName") format("svg");
}
to set the src property to the font URL for various font formats.
Conclusion
To fix the failure to decode downloaded font with CSS, we fix the URL to the font.