-
Notifications
You must be signed in to change notification settings - Fork 377
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug?]: @tailwindcss/vite v4 breaking after dev server restart #1693
Comments
I'm not sure I followed all the way. So Tanstack Start is on Vinxi 0.5.1 and Vite 5 -- and that works, right? Is that the takeaway? Should we pin down Vite to 5 would the issue goes away for us as well? |
No, the takeaway here isn't related to vite/vinxi versions - i see same behavior across versions The takeaway is that tailwindcss v4 doesn't work when installed through the vite plugin in solid-start, but it does work in astro (indicating the tailwind vite plugin is working) and it does work in tanstack start (indicating it might even be a solid-start rather than a vinxi problem) |
Tailwind 4 is has been stable released: So we better make sure it works with SolidStart |
Current behavior 😯
In tailwind 4, which is still only in beta (but it would be good to fix this before they hit stable), there are now two ways to install tailwind.
The vite plugin works as expected when making a prod build, and for the dev server on a clean reload, but if the dev server is restart in solid-start, the style will be broken. To get it working again, it will be necessary to do either of the following:
node_modules/.vinxi
and then restart dev server./src/app.css
- triggering this file reload is enough to make it work againWith Astro (v5), there are no issues with restarting the dev server using @tailwindcss/vite with Solid.
With TanStack Start (vinxi 0.4.3/0.5.1), there are no issues either.
Expected behavior 🤔
I expected the tailwind plugin to load correctly on dev server restart.
Steps to reproduce 🕹
There's a repo here with multiple implementations:
https://github.com/birkskyum/tailwind-vite-repro
I can reproduce this issue with vinxi 0.4.3 / 0.5.0 / 0.5.1 and overrides with vite 5/6
The working output looks like this:
The broken output will look like this:
Context 🔦
No response
Your environment 🌎
No response
The text was updated successfully, but these errors were encountered: