Search code examples
ruby-on-railstwitter-bootstrapiconsfont-awesometwitter-bootstrap-rails

Updating latest FontAwesome icons with Rails Less Bootstrap


FontAwesome released a bunch of awesome new icons and I'm having trouble getting them with my current configuration.

I have a rails application using the "twitter-bootstrap-rails" gem which comes with Fontawesome automatically but it has the old version of FontAwesome that doesn't include the latest icons. I tried what they suggested here but didn't work and ended up messing up everything.

What's the best way to pull the latest FontAwesome icons?

This is how I call FontAwesome in my bootstrap_and_overides.css.less file:

@fontAwesomeEotPath: asset-path("fontawesome-webfont.eot");
@fontAwesomeEotPath_iefix: asset-path("fontawesome-webfont.eot#iefix");
@fontAwesomeWoffPath: asset-path("fontawesome-webfont.woff");
@fontAwesomeTtfPath: asset-path("fontawesome-webfont.ttf");
@fontAwesomeSvgPath: asset-path("fontawesome-webfont.svg");
@import "fontawesome";

Solution

  • The twitter-bootstrap-rails gem uses 3.0.2 fontawesome.

    There is a proposal to update to 3.1.1 on github https://github.com/seyhunak/twitter-bootstrap-rails/issues/571

    Might be worth waiting a little while unless it's super urgent..