Although the built-in sass / inline style sheets are not recommended. I just had a case where I cannot get around it, so if you want to do something like
index.html.haml:
:sass @import my_styles
app / assets / stylesheets / my_styles.css.sass:
body background-color: black
i.e. use your stylesheets in app / assets / stylesheets as inline styles, just add an initializer to your rails application with
::Sass::Plugin.options[:load_paths] = Rails.application.config.sass[:load_paths].to_a
I don't know if this is being used by anyone, but I thought it was worth sharing.
source share