Skip to content

Commit b52b568

Browse files
committed
remove top-level suspense
1 parent 797dd4f commit b52b568

File tree

2 files changed

+8
-12
lines changed

2 files changed

+8
-12
lines changed

hydrate.tsx

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,10 @@ export async function hydrate(
2020
const Initial = await import(matched.value);
2121
return hydrateRoot(
2222
document,
23-
<Suspense>
24-
<RouterHost Shell={Shell}>
25-
<Shell {...globalX.__SERVERSIDE_PROPS__}>
26-
<Initial.default {...globalX.__SERVERSIDE_PROPS__?.props} />
27-
</Shell>
28-
</RouterHost>
29-
</Suspense>
23+
<RouterHost Shell={Shell}>
24+
<Shell {...globalX.__SERVERSIDE_PROPS__}>
25+
<Initial.default {...globalX.__SERVERSIDE_PROPS__?.props} />
26+
</Shell>
27+
</RouterHost>
3028
);
3129
}

index.tsx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,9 @@ export class StaticRouters {
8383
});
8484
}
8585
const stream = await renderToReadableStream(
86-
<Suspense>
87-
<Shell {...result}>
88-
<module.default {...result?.props} />
89-
</Shell>
90-
</Suspense>,
86+
<Shell {...result}>
87+
<module.default {...result?.props} />
88+
</Shell>,
9189
{
9290
signal: request.signal,
9391
bootstrapScriptContent: [

0 commit comments

Comments
 (0)