我只是在摆弄一些东西,碰巧在我的ruby on rails app上运行bundle install.我注意到bootstrap从3.1.1更新到3.2.0,现在当我去生成某些视图时,我收到此错误:
ActionController::RoutingError (No route matches [GET] "/fonts/bootstrap/glyphicons-halflings-regular.ttf"):
Run Code Online (Sandbox Code Playgroud)
直到这个宝石更新才发生.有什么建议?我已经尝试在Gemfile中明确使用3.1.1并再次运行bundle,但这没有帮助.它看起来就像一个简单的路由问题,但是为什么这只会在gem更新期间发生变化.
我的问题在于我在application.css.scss文件中导入bootstrap的顺序.确保订单顺利进行:
@import "bootstrap-sprockets";
@import "bootstrap";
Run Code Online (Sandbox Code Playgroud)
对于其他无法获得答案的人,我手动更改了此文件:
/home//.rvm/gems/ruby-2.1.1/gems/bootstrap-sass-3.2.0.2/assets/stylesheets/bootstrap/_glyphicons.scss 并取出 $icon_path 或任何内容并将其替换为“。 ./资产/引导/
之后修复了该问题。
| 归档时间: |
|
| 查看次数: |
1232 次 |
| 最近记录: |