Closed gaearon closed 7 months ago
I got the same error
Ah, yep, this is happening for me with new projects now too. Something pushed recently? I've tried rolling the version back in package.json, but that didn't work.
However if I copy this https://github.com/zachlankton/playing-with-server-components/blob/main/solidjs/package-lock.json lock file into the project and re-run npm install
it works.
There are a few older dependencies in that lock file.
Here's a repro. Crashing in pnpm dev
but working in build mode.
I could narrow it down. The issue started from the bump of solid-refresh from v0.6.3 to v0.7.0.
Temporal fix:
"pnpm": {
"overrides": {
"solid-refresh": "0.6.3"
}
}
You guys can share if doing this fixes your hydration issue. It will be easier to find the root cause.
temporary fix for now is to set the resolution for solid-refresh to 0.6.3
I still yet have to test the new refresh in Start, but things got a little unexpected domino effect.
Vite Plugin Solid did an update that grabbed the latest Solid Refresh that introduces a new granular HMR stragety. The range in Solid Start is only locked to the nearest major in Start and it broke everything. I'm going to set the range to minor in Start and we can test the new Vite plugin. Sorry for the inconvenience.
v0.5.7 is now released that locks the version to minor version of vite-plugin-solid. Development of new Solid Start projects now won't be affected while we track down the issue with Solid Refresh.
The same thing happens with
"@solidjs/router": "0.12.4",
"@solidjs/start": "0.5.10",
"solid-js": "1.8.15",
"vinxi": "0.3.3"
Any updates?
UPDATE: fixed this with using Suspense
in app.tsx
We are still testing the new Refresh plugin I'm going to consider this one closed because we already reverted the broken build. We will worry about the new Refresh plugin when it is ready.
Duplicates
Latest version
Current behavior 😯
Result:
Expected behavior 🤔
No mismatch in a fresh project
Steps to reproduce 🕹
See above
Context 🔦
Creating a project
Your environment 🌎