mirror of
https://github.com/hanzoai/next.js.git
synced 2026-09-24 17:00:51 +00:00
x-ref: https://github.com/vercel/next.js/pull/46271 x-ref: https://github.com/vercel/next.js/pull/46081
18 lines
360 B
JavaScript
18 lines
360 B
JavaScript
export default async function Page() {
|
|
const data = await fetch(
|
|
'https://next-data-api-endpoint.vercel.app/api/random',
|
|
{
|
|
headers: {
|
|
Authorization: 'Bearer token',
|
|
},
|
|
}
|
|
).then((res) => res.text())
|
|
|
|
return (
|
|
<>
|
|
<p id="page">/variable-revalidate/authorization</p>
|
|
<p id="page-data">{data}</p>
|
|
</>
|
|
)
|
|
}
|