rails / cssbundling-rails

Bundle and process CSS in Rails with Tailwind, PostCSS, and Sass via Node.js.
MIT License
579 stars 83 forks source link

Sprockets still looking for `sassc` #10

Closed ghost closed 3 years ago

ghost commented 3 years ago

Been trying out the new pipeline with sass as the --css option in Rails. It seems that Sprockets is still looking for sassc, which causes a Rails exception. Dart Sass is compiling fine to the build directory, so just looks like a legacy dependency issue.

I could get it working fine by uncommenting sassc-rails in the Gemfile, however this is obviously not needed with Dart Sass. I'm happy to open a PR on Rails main to remove the dependency if this is the agreed route.

dhh commented 3 years ago

I saw this and think I have a solution. We have to remove the link_tree stylesheets from the config/manifest.js. Will get this sorted.

ghost commented 3 years ago

Ah, of course — I forgot about the magic comments in Sprockets. Are they relevant anymore with the shiny new setup?

ghost commented 3 years ago

I can confirm that removing the link_tree line for the stylesheets in manifest.json fixes the issue. Would you like me to open a PR, or are you on it?

dhh commented 3 years ago

Fixed within https://github.com/rails/cssbundling-rails/pull/3 👍