Skip to content
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

HMR does not pickup windi config's customisations if they were not used before the cold start #236

Open
bhvngt opened this issue Sep 17, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@bhvngt
Copy link
Contributor

bhvngt commented Sep 17, 2021

Describe the bug

I have an app that uses svelte, windicss and vite. Customisation made within windi.config.js if not used before cold start are not getting picked up by the HMR.

Minimal Reproductions
Here's the codesandbox that produces this bug.

  1. bg-primary is used in App.svelte
  2. When vite is started it correctly reflects the custom color.
  3. When the value of primary is changed it gets pickedup by vite's HMR and is reflected on the site.
  4. If the class is now changed to bg-secondary which was not used in the app earlier, though vite's file watcher records the change, the class itself is not reflected in the output. Possibly because it does not get sent to the browser by windicss

Versions

  • vite-plugin-windicss: 1.4.3
  • vite: 2.5.7
  • framework(vue/react/svelte/etc): svelte
@bhvngt bhvngt added the bug Something isn't working label Sep 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant