Files
Josh StoryandGitHub d424aa8ec4 Stabilize unstable_instant (#94578)
This API has experimental modes for build validation but the dev
validation is going to be stable in the next release.
2026-06-09 13:50:25 -07:00

33 lines
760 B
TypeScript

import { cookies } from 'next/headers'
import { connection } from 'next/server'
export const instant = { level: 'experimental-error' }
export default async function Page() {
return (
<main>
<p>
This page doesn't wrap runtime/dynamic components in suspense, but it
has a loading.tsx. a self-navigation with a different search param value
would block, but we accept that.
</p>
<div>
<Runtime />
</div>
<div>
<Dynamic />
</div>
</main>
)
}
async function Runtime() {
await cookies()
return <div id="runtime-content">Runtime content from page</div>
}
async function Dynamic() {
await connection()
return <div id="dynamic-content">Dynamic content from page</div>
}