【发布时间】:2017-09-16 16:00:17
【问题描述】:
在我的 Rails 5 应用程序中,我的 application.sass 文件中有这个...
/*
*= require bootstrap-sass-official
...
*/
@font-face
font-family: 'Glyphicons Halflings'
src: url('/assets/glyphicons-halflings-regular.eot')
src: url('/assets/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('/assets/glyphicons-halflings-regular.woff') format('woff'), url('/assets/glyphicons-halflings-regular.ttf') format('truetype'), url('/assets/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg')
...根据Ruby on Rails Bootstrap Glyphicons not working 中的建议。我在 Chrome 控制台中收到此错误:Failed to decode downloaded font: http://localhost:3000/assets/glyphicons-halflings-regular.woff, etc.. 用于各种字体格式。
我需要将任何东西放入我的 Rails 资产fonts 文件夹吗?如果有,具体是什么?非常感谢您对此提供的任何帮助。
【问题讨论】: