Rails using Bootstrap templates in vendor

If you are considering using templates which you copied to vendor directory then things you need to keep in mind:-

  • Move all assets like Images, sounds, Fonts but not js or css to vendor/assets/ like
    • vendor/assets/fonts
  • Add this line in assets.rb
    • Rails.application.config.assets.precompile << /\.(?:svg|eot|woff|ttf)\z/
  • Make sure you are using `rails_12factor` gem in production
  • use image-url and font-url helpers
  • in scss files in @imports rule you do not use .css at last of the filename. It automatically calculates.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s