v4.0.0-rc1 - Bundled application.tailwind.css gets 404 trying to load /assets/tailwindcss
aguynamedben opened this issue · 4 comments
Hi, thank you for making this library. It's been awesome to get setup.
I have everything working, and it looks great, but I noticed in my Chrome Dev Tools Console an error:
The error doesn't seem to be breaking anything, but I'm not sure what's triggering it. It seems that the bundled version of application.tailwind.css, which just has the contents @import "tailwindcss"; is triggering a network call to GET http://localhost:3000/assets/tailwindcss. I'm not super familiar with the @import statement in CSS, but I find that odd.
The Sources tab shows:
If I comment out that import in application.tailwind.css in an attempt to stop the error, Tailwind stops loading all together and my page formatting goes ugly.
This is a pretty "stock" v4.0.0-rc1 install. Screenshots of my diff below.
tailwind.config.js deleted, because I basically got to 4.0.0-rc1 but removing everything from 3.x and running the tailwindcss:install task with 4.x which doesn't install tailwind.config.js.

Thanks for the clear bug report. Looking at it now.
Proposed fix is at #474
UPDATE: Fixed in rc3. Thanks!
Not sure w're all the way there yet on this one...
I just went through the upgrade process using tailwindcss-rails v4 rc2. I'm on rails v8. I'm somehow still getting a reference to tailwindcss (no fingerprint) as a plain type. I can't figure out why or how.
Can confirm that the old <%= stylesheet_link_tag "tailwind", "data-turbo-track": "reload" %> was removed from my application layout via your wonderful update utility (rails tailwindcss:upgrade): pdobb/minesweeper_alliance@1b1e7e7#diff-f43fe075643e681b2c01c2f853bb0c4299d135b47fcbd4da96890d521c49e3ebL20
Not sure what to investigate, but happy to if it helps. Thanks!
This happens due to stylesheet_link_tag helper when you pass the :all or :app flag. I created a new issue at #477