next.js/test/e2e/app-dir/cache-components/app/date/now/cached/page.tsx
page.tsx20 lines352 B
import { SentinelValue } from '../../../getSentinelValue'

export default async function Page() {
  const now = await getNow()
  return (
    <div>
      <label>now</label>
      <span id="value">{now}</span>
      <span id="page">
        <SentinelValue />
      </span>
    </div>
  )
}

async function getNow() {
  'use cache'
  return Date.now()
}
Quest for Codev2.0.0
/
SIGN IN