Ask A Question

Notifications

You’re not receiving notifications from this thread.

Why does my bootstrap not work across the application. Rails 5

Thomaz Wanderbruck Schmidt asked in Rails

I'm starting a project with rails 5 and the first thing I did was add the bootstrap to rails 5. I added the gem and imported it into application.scss. I generated a devise Admin and the bootstrap worked, but then I generated a controller with the following command Rails generate backend / dashboard index. On this backend dashboard my bootstrap is not working.

here my application.scss

/
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS and SCSS file within this directory, lib / assets / stylesheets, or any plugin's
 * vendor / assets / stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS / SCSS
 * files in this directory. Styles in this file should be added after the last require_ * statement.
 * It is generally better to create a new file per style scope.
 *
 * /

// Custom bootstrap variables must be set or imported * before * bootstrap.
@import "bootstrap";

Reply
Join the discussion
Create an account Log in

Want to stay up-to-date with Ruby on Rails?

Join 86,946+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.