Files
7d12945191 Ensure stale build fetch data is not unexpectedly used (#59076)
If a build time fetch cache is present from a previous build we don't
want to unexpectedly use it when flush to disk is set to false in a
successive build as it can leverage stale data unexpectedly.

x-ref: [slack
thread](https://vercel.slack.com/archives/C03S8ED1DKM/p1701266754905909)

Closes NEXT-1750

Co-authored-by: Zack Tanner <[email protected]>
2023-11-29 10:03:25 -08:00

17 lines
310 B
TypeScript

import React from 'react'
export const revalidate = 30
export default async function Page() {
const data = await fetch(
'https://next-data-api-endpoint.vercel.app/api/random'
).then((res) => res.text())
return (
<>
<p id="page">index page</p>
<p id="data">{data}</p>
</>
)
}