Extending Bootstrap default look in a Rails project

in #utopian-io7 years ago


There is a new way of customizing your styling in Bootstrap 4. You can import the particular Bootstrap component you would want to modify. I normally find myself modifying colors in most of my Rails Projects.

@import '/bootstrap/_variables.scss'   // The source of my Bootstrap
  // Colour Scheme
  $primary:   #1a284d  // My primary colour
  $secondary: #1eff23  // My Secondary colour 

Then I allow the bootstrap gem and sass-rail gem to make the compilation for me.

`Gem file`
...
  # Bootstrap Gem for my HTML framework
  gem 'bootstrap', '~> 4.1.1'
  # Use SCSS for stylesheets
  gem 'sass-rails', '~> 5.0'
...

Coin Marketplace

STEEM 0.21
TRX 0.21
JST 0.035
BTC 91680.24
ETH 3137.17
USDT 1.00
SBD 3.00