son*_*olo 10 fonts font-face meteor
我试图在流星中使用CSS @ font-face,但由于某种原因它不起作用:
@font-face {
font-family: printFailed;
src:
url("../public/fonts/wlm_print_failed.ttf"),
url("../public/fonts/wlm_print_failed.eot");
}
Run Code Online (Sandbox Code Playgroud)
我检查了我的路径和拼写.
当我在浏览器中检查元素时,看起来文件路径和名称是正确的,但浏览器替换了通用字体而不是预期的自定义字体.
有什么指针吗?谢谢.
Aks*_*hat 27
从Web浏览器的角度来看,只需将/所有内容用作public根目录:
@font-face {
font-family: printFailed;
src:
url("/fonts/wlm_print_failed.ttf"),
url("/fonts/wlm_print_failed.eot");
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
7412 次 |
| 最近记录: |