Reputation: 31
I have a simple ROR project and I want to use Bootstrap-sass. I've added it to my Gemfile, run bundle install and have added "@import "bootstrap";" as the very first line of my css file. As a quick test, I've cut and pasted an example of a couple of buttons with various styles.
They show up on the webpage as a couple of plain buttons.
How can I tell if bootstrap is actually getting loaded?
Update: Looking at the error console of the browser, I see the following message: 'The stylesheet localhost:3000/assets/bootstrap was not loaded because its MIME type, "application/javascript", is not "text/css"'
Any thoughts?
Thanks,
Upvotes: 1
Views: 1852
Reputation: 6915
I solved problem by renaming application.css to application.scss
First I think I did that, but apparently I didn't save the renamed file name.
Upvotes: 2
Reputation: 25
I remember the first time I worked with bootstrap it didn't work. It was because I didn't point the document root to the right place. Of course I usually check the document root because it a reoccurring problem for me, and now that I know I tend to make an error there I start there. I will say that taking time to look at the type of mistakes I make frequently has helped my growth.
Upvotes: 0
Reputation: 424
To start you can check your browser console's NET panel. It should show a request for 'bootstrap.css'. It sure sounds like it's not being pulled in. This would be the first step in confirming.
Upvotes: 0