Loading…
This is the loading.tsx fallback. The PRISM runtime streamed it immediately while the sibling page.tsx's loader was still suspended on a 1.5s sleep.
This is the loading.tsx fallback. The PRISM runtime streamed it immediately while the sibling page.tsx's loader was still suspended on a 1.5s sleep.
A sibling loading.tsx auto-wraps the page tree in a Suspense boundary. Async pages stream the fallback first, then emit the real content via the framework's out-of-order template+swap protocol — same machinery the explicit <Suspense> demos use.
Page resolved at 2026-06-15T17:56:20.648Z. Reload — you should see the Loading… fallback flash for ~1.5s in streaming mode before this content swaps in.
(View source to see both the fallback and the real content in the body, with a __bextSuspense.swap(N) inline script wiring them together. The fallback ships immediately; the real content arrives ~1.5s later as a separate chunk.)
// src/app/examples/loading-demo/loading.tsx
export default function Loading() {
return <h1>Loading…</h1>;
}
// src/app/examples/loading-demo/page.tsx
export default async function Page() {
await new Promise((r) => setTimeout(r, 1500));
return (
<div>
<h1>loading.tsx</h1>
<p>Resolved at {new Date().toISOString()}</p>
</div>
);
}