mirror of
https://github.com/hanzoai/next.js.git
synced 2026-10-30 14:46:38 +00:00
10 lines
200 B
TypeScript
10 lines
200 B
TypeScript
export default function Post({ id }: { id: string }) {
|
|
return <div>Post {id}</div>
|
|
}
|
|
|
|
export async function getServerSideProps(context: any) {
|
|
return {
|
|
props: { id: context.params.id },
|
|
}
|
|
}
|