-
Notifications
You must be signed in to change notification settings - Fork 86
/
Copy pathpage.js
39 lines (37 loc) · 952 Bytes
/
page.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import Link from 'next/link'
export default async function Page({ params }) {
await fetch('http://example.com', {
next: { revalidate: 10 },
})
return (
<>
<p id="page">/blog/[author]</p>
<p id="params">{JSON.stringify(params)}</p>
<p id="date">{Date.now()}</p>
<Link href="/blog/erica" id="author-1">
/blog/erica
</Link>
<br />
<Link href="/blog/sarah" id="author-2">
/blog/sarah
</Link>
<br />
<Link href="/blog/nick" id="author-3">
/blog/nick
</Link>
<br />
<Link href="/blog/erica/first-post" id="author-1-post-1">
/blog/erica/first-post
</Link>
<br />
<Link href="/blog/sarah/second-post" id="author-2-post-1">
/blog/sarah/second-post
</Link>
<br />
<Link href="/blog/nick/first-post" id="author-3-post-1">
/blog/nick/first-post
</Link>
<br />
</>
)
}