File tree Expand file tree Collapse file tree 3 files changed +8
-5
lines changed Expand file tree Collapse file tree 3 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,7 @@ export default class Comment extends React.Component {
1414 return (
1515 < div className = "comment" >
1616 < div className = "meta" >
17+ { /* TODO: time hydration mismatch */ }
1718 { user } { timeAgo ( new Date ( date ) ) } ago{ ' ' }
1819 < span onClick = { this . toggle } className = "toggle" >
1920 { this . state . toggled
Original file line number Diff line number Diff line change 11import Head from 'next/head'
2- // import Router from 'next/router'
32
43export default function Meta ( ) {
54 return (
Original file line number Diff line number Diff line change 11import ItemPage from '../components/item.server'
22
3- export default function Item ( { router } ) {
4- const { id } = router . query
3+ export default function Item ( { id } ) {
54 return < ItemPage id = { id } />
65}
76
8- export const config = {
9- runtime : 'edge' ,
7+ export async function getServerSideProps ( { query } ) {
8+ return {
9+ props : {
10+ id : query . id
11+ }
12+ }
1013}
You can’t perform that action at this time.
0 commit comments