I just ran your app locally and am having no issues with the css file loading, though I didn’t worry about precompiling the assets. Have you refreshed your browser to try reloading the changes?
Thanks for looking into this. Refreshing my browser doesn’t help. I just changed some styles and it doesn’t have any effect whatsoever. This is very strange, also when I implement some Bourbon mixins like
No problems, I believe because you have the assets precompiled, its not going through to sprockets as its already found some assets to utilise. Can you try deleting those compiled assets and letting me know how you get on?
I’m assuming you’ve tried force-refreshing your browser too? cmd + F5 on a mac should do it. If not let me know and I’m happy to pair with you and take a quick look.
@acandael, did you restart your Rails server? Settings like what assets are supposed to be precompiled or included I think are set at startup. Editing an already included stylesheet shouldn’t require a restart, but a brand-new stylesheet might.
@Tom, @Geoff, I think something seriously messed up my application, so I decided to rebuild the application from scratch. Now everything runs fine.
To implement the onepage-scroll.css stylesheet for the homepage, I use page styles with the style-tag in my homepage view template. I know, it isn’t pretty, but it works.
The only issue I had to fix was that the onepage-scroll css defines fixed positioning for the html-element. When clicking a link on the homepage, because of turbolinks, the html-element of the referenced page also had a fixed positioning.
So to fix that issue, I had to turn off turbolinks with:
data: { no_turbolink: true }
in the link element.
That said, I think it’s the last time time I use the One Page Scroll plugin in a Rails project. It gave me a lot headaches : )
Also Turbolinks is giving me a lot of headaches, I really hope they dish this feature in Rails 5.