mirror of
https://github.com/hanzoai/next.js.git
synced 2026-10-30 14:46:38 +00:00
This ensures we de-dupe inflight `getStaticProps` requests the same way we do `getServerSideProps`, this also removes the `_getStaticData` and `_getServerData` methods as they were repeating the same logic so could be combined into `fetchNextData`.
7 lines
218 B
JavaScript
7 lines
218 B
JavaScript
export async function getStaticProps() {
|
|
await new Promise((resolve) => setTimeout(resolve, 2000))
|
|
return { props: { message: 'hello world' } }
|
|
}
|
|
|
|
export default ({ message }) => <p id="content">slow {message}</p>
|