Skip to content

Commit 80ca972

Browse files
committed
fix onHydrate call being skipped
1 parent 45c5e64 commit 80ca972

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"solid-js": patch
3+
---
4+
5+
fix `onHydrate` call being skipped

packages/solid/src/reactive/signal.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -692,12 +692,12 @@ export function createResource<T, S, R>(
692692
loadEnd(pr, p, undefined, lookup);
693693
return p;
694694
}
695+
pr = p;
695696
if ("value" in p) {
696697
if ((p as any).status === "success") loadEnd(pr, p.value as T, undefined, lookup);
697698
else loadEnd(pr, undefined, undefined, lookup);
698699
return p;
699700
}
700-
pr = p;
701701
scheduled = true;
702702
queueMicrotask(() => (scheduled = false));
703703
runUpdates(() => {

0 commit comments

Comments
 (0)