2
votes

I have file app/assets/stylesheets/themes/plexa/home.sass

  1. Added to config/manifest.js

    //= link themes/plexa/home.css

  2. Check http://localhost:3000/assets/themes/plexa/home.css - It works, I see css!

  3. But if I add to rails layout:

stylesheet_link_tag "themes/plexa/home" This doesn't work!

It raise rails exception: ActionView::Template::Error at / themes/plexa/home.css

Tried with debugger:

byebug) stylesheet_link_tag "themes/plexa/home"
*** Sprockets::Rails::Helper::AssetNotPrecompiled Exception: themes/plexa/home.css

I read all sprockets docs and upgrade guide but doesn't understand why stylesheet_link_tag doesn't works ( Rails 5.1)

Update: = stylesheet_link_tag "/assets/themes/plexa/home" Works, but I doesn't understand why I need to setup assets path?

1

1 Answers

0
votes

Update: Sprockets has not been updated that's why manifest.js ignored because there is an old ruby version 2.4.6, which need to update