I created a new Rails 8 app with bootstrap css:
rails new my_app -c="bootstrap"
and Bootstrap worked out of the box. It created an application.bootstrap.scss file that included:
@import 'bootstrap/scss/bootstrap';
@import 'bootstrap-icons/font/bootstrap-icons';
I added:
$primary: #792c2c;
$theme-colors: (
'primary': $primary
);
and it did nothing. I tried stopping the server and running rails assets:precompile
but that also did nothing.
I created a new Rails 8 app with bootstrap css:
rails new my_app -c="bootstrap"
and Bootstrap worked out of the box. It created an application.bootstrap.scss file that included:
@import 'bootstrap/scss/bootstrap';
@import 'bootstrap-icons/font/bootstrap-icons';
I added:
$primary: #792c2c;
$theme-colors: (
'primary': $primary
);
and it did nothing. I tried stopping the server and running rails assets:precompile
but that also did nothing.
Add the updated definition before the Bootstrap import:
$primary: #792c2c;
$theme-colors: (
'primary': $primary
);
@import 'bootstrap/scss/bootstrap';
@import 'bootstrap-icons/font/bootstrap-icons';