fc7e235f2c
* Add checking for hybrid AMP during static check * Update to always hit server for prerender data * Add removing of SPR code when not used * Add checking for hybrid AMP during static check * Update to always hit server for prerender data * Add removing of SPR code when not used * Update dead code elimination
18 lines
337 B
JavaScript
18 lines
337 B
JavaScript
import Link from 'next/link'
|
|
|
|
export const config = { experimentalPrerender: true }
|
|
|
|
const Comment = ({ data }) => (
|
|
<>
|
|
<p>Comment: {data}</p>
|
|
<Link href='/'>
|
|
<a id='home'>to home</a>
|
|
</Link>
|
|
</>
|
|
)
|
|
|
|
Comment.getInitialProps = () => ({
|
|
data: typeof window === 'undefined' ? 'SSR' : 'CSR'
|
|
})
|
|
|
|
export default Comment
|