You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I got a very simple setup, just ran "bun create solid" to try out solid, and then added a fetch call outside, the entire setup can be found here: https://github.com/GustavBW/helldiving
The culprit is something to do with the createResource signal, as when I remove it, everything works just fine. However, if it remains then sometimes, like 8/10 times, I get the aforementioned hydration error.
Stack trace:
Error: Hydration Mismatch. Unable to find DOM nodes for hydration key: 0-0-0-0-0-0-0-5
at getNextElement (chunk-JSAOQG5U.js?v=0b822351:276:37)
at get children (app.tsx:22:31)
at Show.createMemo.name [as fn] (chunk-SR3X3KTH.js?v=0b822351:1495:27)
at runComputation (chunk-SR3X3KTH.js?v=0b822351:707:22)
at updateComputation (chunk-SR3X3KTH.js?v=0b822351:689:3)
at Object.readSignal (chunk-SR3X3KTH.js?v=0b822351:625:67)
at Object.fn (chunk-JSAOQG5U.js?v=0b822351:238:58)
at runComputation (chunk-SR3X3KTH.js?v=0b822351:707:22)
at updateComputation (chunk-SR3X3KTH.js?v=0b822351:689:3)
at createRenderEffect (chunk-SR3X3KTH.js?v=0b822351:218:75)
(Also amazing error feedback btw)
I've also tested and confirmed that the pretty-print-json shenanigans I'm doing are not the culprit.
Interestingly, if I press the "reset error" button on the error prompt, everything works and the page loads in correctly. However, if I just reload the page, we're back to chance.
Expected behavior 馃
Not much really. Just a massive, failed html-ified json dump.
Steps to reproduce 馃暪
Steps:
Pull the repo
cd /helldiving
bun install
bun run dev
open in chrome
reload the page until error. (Should happen pretty fast, I have an 80% error rate)
Context 馃敠
I'm just trying to get started with Solid (coming from React)
This whole section might just be the cause of it. In general, I just can't recommend the use of loading and error properties over Suspense and ErrorBoundary, due to the former's quirky behavior
This whole section might just be the cause of it. In general, I just can't recommend the use of loading and error properties over Suspense and ErrorBoundary, due to the former's quirky behavior
Suspense doesn't seem to work either it just fallbacks regardless.
I rewrote the main statement to:
The data is present btw. I tried console.logging it and it does fetch successfully. I could go completely React on this and manually taking over control flow, and it'd probably work, but I don't think that's how its supposed to be done in Solid.
Duplicates
Latest version
Current behavior 馃槸
I got a very simple setup, just ran "bun create solid" to try out solid, and then added a fetch call outside, the entire setup can be found here:
https://github.com/GustavBW/helldiving
99% of the code:
The culprit is something to do with the createResource signal, as when I remove it, everything works just fine. However, if it remains then sometimes, like 8/10 times, I get the aforementioned hydration error.
Stack trace:
(Also amazing error feedback btw)
I've also tested and confirmed that the pretty-print-json shenanigans I'm doing are not the culprit.
Interestingly, if I press the "reset error" button on the error prompt, everything works and the page loads in correctly. However, if I just reload the page, we're back to chance.
Expected behavior 馃
Not much really. Just a massive, failed html-ified json dump.
Steps to reproduce 馃暪
Steps:
Context 馃敠
I'm just trying to get started with Solid (coming from React)
Your environment 馃寧
The text was updated successfully, but these errors were encountered: