Skip to content

Commit c0d4659

Browse files
committed
Slightly better ssr example
1 parent 0bdf789 commit c0d4659

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

apps/next/app/ssr/page.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@ import { SSRTestScreen } from './screen'
33
export const runtime = 'edge'
44

55
export default function Page() {
6-
return <SSRTestScreen></SSRTestScreen>
6+
const content = 'This page is rendered on the edge. It is not statically rendered.'
7+
return <SSRTestScreen content={content}></SSRTestScreen>
78
}

apps/next/app/ssr/screen.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22

33
import { Paragraph, YStack } from '@t4/ui'
44

5-
export function SSRTestScreen() {
5+
export function SSRTestScreen(props: { content: string }) {
66
return (
77
<YStack flex={1}>
88
<Paragraph role='heading'>
9-
This page is rendered on the edge. It is not statically rendered.
9+
{props.content}
1010
</Paragraph>
1111
</YStack>
1212
)

0 commit comments

Comments
 (0)