I keep encountering this error in Chrome and unfortunately my search for a solution hasn't been very successful. Although the font displays correctly, I still receive this warning message. Here is the full warning:
"Failed to decode downloaded font: http://localhost:8000/app/fonts/Lato/"
The CSS rules I am using are as follows:
@font-face {
font-family:"Lato";
src: url("../fonts/Lato/");
}
html, body {
font-family:'Lato';
}
It's puzzling to me. The font is being implemented properly, yet the warning persists. If I try using Sans-Serif
, the font reverts to the default browser font. This may be the cause, but I can't be certain since my searches have yielded no results. Any help is appreciated!
UPDATE
I have multiple font files, all belonging to the same family. I want to load each of them. These font files are in .ttf
format. They are stored in a local directory, and include files such as Lato-Black.ttf
, Lato-Bold.ttf
, Lato-Italic.ttf
and so on.