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

solid-refresh HMR doesn't work properly for the JS template #30

Open
lxsmnsyc opened this issue Feb 4, 2022 · 4 comments
Open

solid-refresh HMR doesn't work properly for the JS template #30

lxsmnsyc opened this issue Feb 4, 2022 · 4 comments
Labels
bug Something isn't working

Comments

@lxsmnsyc
Copy link
Member

lxsmnsyc commented Feb 4, 2022

This is a very weird case I believe, only the JS template has its HMR completely bugged. Compilation is correct for both babel-preset-solid and solid-refresh, the replacement module actually gets loaded (at least on Vite's client) however it seems that it doesn't send the replacement module to the module accept part (I have not tested this fully yet, but it might be the case). The bug is that even if the HMR update goes through, the component does not get replaced.

If anyone can reproduce this on other bundler setup, the issue might be on solid-refresh' side.
If this only happens on Vite, the issue might be either on Vite or the plugin.

@electroheadfx
Copy link

I have exactely the same issue for js template , thanks. add /* @refresh reload */ in frontmatter file seem to solve the issue per file.

@ff2400t
Copy link

ff2400t commented Feb 26, 2022

I have the same issue , but the ts-windicss template has worked for me 🤔

@lxsmnsyc
Copy link
Member Author

I have the same issue , but the ts-windicss template has worked for me 🤔

yeah it seems that only the JS template is broken, the other template works perfectly fine, I'm not entirely sure why

@linorabolini
Copy link

I have the same problem. The hot reloading, depending on what update to the code is made, may or may not break the page, so I end up needing to reload the entire page anyways.

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

5 participants