-
-
Notifications
You must be signed in to change notification settings - Fork 6.1k
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
Vite + Tailwind automatic full page reload #5808
Comments
downgrade vite to version 2.6.1 to resolve this issue. |
Downgrading didn't prevent this for me |
Downgrading to 2.3.8 resolved the issue for me |
Just tested with 2.8.6, which includes #6959 , and I'm still seeing this :( |
Hello @TomDeSmet. Please provide a minimal reproduction using a GitHub repository or StackBlitz. Issues marked with |
Please provide a reproduction if this still happens. It's hard to find a fix to resolve the issue without a repro to test and verify against. |
Describe the bug
I'm not sure if this is a bug with Vite or Tailwind, but it looks similar to #4147, #4267 and #4150. The difference is that this "bug" actually works too good (which is a weird thing to say I know).
HMR works perfectly as it should, but when altering files that Tailwind lists in its
purge
list in the Tailwind config, the browser reloads automatically. This shouldn't be happening. Normally, we use the ViteRestart plugin to tell Vite it needs to watch some files that are not JS, and if they change it should reload the browser.But as I read in the linked git issues, this is because Tailwind adds them as dependencies and Vite picks them up. This should be fixed in 2.4.3 but not the issue I have.
Reproduction
I think it is clear.
System Info
Used Package Manager
npm
Logs
No response
Validations
The text was updated successfully, but these errors were encountered: