Description
I can't replicate this so I'm going to create this issue then close it in hopes it helps some other poor bugger googling the issue. When I was running my rails server (locally only) and running Tailwind in watch mode, I had a funny issue where Tailwind was producing a new version of application.css
but my rails server was not using the new version.
If I restarted the rails server, it had no effect. If I ran rails assets:precompile', it would produce a new version of the tree-shaken
applicaiton.css` but the dev server would not use it. I could not use new tailwind classes in my code.
The solution: rails assets:clobber
That sorted it out and got my server acting as expected. I have no idea why. This was running on a project that was a couple hours hold running Rails 7.0, Ruby 3.0.3 and using the tailwindcss-rails gem for Tailwind.
I have tried to replicate this but have not been able to. Hoping at least this will help someone else from a couple of hours tearing out their hair.