00ed2ba7cc
When revalidate isn't defined in the tree at all and a fetch without cache/revalidate fields is done we are incorrectly marking the initial revalidate period with a time based value when it should be `false`. This causes pages that should be fully static to revalidate unexpectedly. x-ref: [twitter thread](https://twitter.com/diegohaz/status/1655638433795014657) x-ref: [slack thread](https://vercel.slack.com/archives/C03S8ED1DKM/p1683566860136879)
15 lines
357 B
JavaScript
15 lines
357 B
JavaScript
export default async function Page() {
|
|
console.log('rendering index')
|
|
|
|
const data = await fetch(
|
|
'https://next-data-api-endpoint.vercel.app/api/random?page'
|
|
).then((res) => res.text())
|
|
|
|
return (
|
|
<>
|
|
<p id="page">/variable-revalidate/revalidate-360</p>
|
|
<p id="page-data">{data}</p>
|
|
<p id="now">{Date.now()}</p>
|
|
</>
|
|
)
|
|
}
|