Skip to content

Upgrade to solid-refresh 0.7#240

Open
lxsmnsyc wants to merge 1 commit intomainfrom
refresh-0.7
Open

Upgrade to solid-refresh 0.7#240
lxsmnsyc wants to merge 1 commit intomainfrom
refresh-0.7

Conversation

@lxsmnsyc
Copy link
Member

No description provided.

@changeset-bot
Copy link

changeset-bot bot commented Feb 25, 2026

⚠️ No Changeset found

Latest commit: 0b34407

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@pkg-pr-new
Copy link

pkg-pr-new bot commented Feb 25, 2026

Open in StackBlitz

npm i https://pkg.pr.new/vite-plugin-solid@240

commit: 0b34407

@ryansolid
Copy link
Member

I was working on the 2.0 branch and saw HMR appeared broken because of changes made here. We should confirm that. I'm going to patch something for 2.0 for now. But @lxsmnsyc we probably need to review what the proper fix is for refresh 0.7 before merging this. I'm not sure the intention but AI reported:

Root cause: Commit ad30cba ("fix #22") deleted get-vite-hmr-requirement.ts which generated import.meta.hot.accept() in the module code. The rationale was that $$refreshESM already calls hot.accept() at runtime. However, Vite's server-side importAnalysis plugin statically lexes the transformed source for the literal pattern import.meta.hot.accept (see Vite source line ~30034) to mark modules as isSelfAccepting. Without it, Vite sends full-reload instead of hot-update.

The decline path (get-hmr-decline-call.ts:11-30) still emits import.meta.hot.accept() directly for Vite -- only the normal refresh path lost it.

@lxsmnsyc
Copy link
Member Author

lxsmnsyc commented Mar 3, 2026

@ryansolid solidjs/solid-refresh#63

If Vite changed their import analysis again I'll probably have to revert that change, will check again

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants