rails/tailwindcss-rails

The tailwindcss compile command ignores `Rails.config.assets.compress = false`

luke-gru opened this issue · 2 comments

Right now it adds the --minify flag even if Rails.config.assets.compress = false. I think it shouldn't add this flag in that case.

@luke-gru This gem can be configured to not minify by passing a debug argument to the rake task, i.e. rails tailwindcss:build[debug] or rails tailwindcss:watch[debug]., see https://github.com/rails/tailwindcss-rails?tab=readme-ov-file#building-unminified-assets

I believe Rails.config.assets.compress has been deprecated for some time. I'm not very familiar with Sprockets, to be honest, but I can't find any reference to it in the modern Rails or Sprockets code bases.

Note that we do pay attention to the modern CSS pipeline, and if a CSS compressor is separately configured this gem won't minify (see #253). I understand that's not what you're asking about, but I bring it up to indicate that we do care about the integration. Can you point me at documentation about Rails.config.assets.compress?

Happy to discuss more if you can help me understand what you're seeing, but closing for now.