next.js/test/e2e/middleware-shallow-link/app/pages/page2.js
page2.js26 lines468 B
import Link from 'next/link'
import React from 'react'

const Page = () => {
  return (
    <>
      <h1>Content for page 2</h1>
      <Link
        data-next-shallow-replace
        replace
        shallow
        href={{ query: { params: 'testParams' } }}
      >
        Shallow replace
      </Link>
      <div>
        <button data-go-back onClick={() => window.history.back()}>
          Go Back
        </button>
      </div>
    </>
  )
}

export default Page
Quest for Codev2.0.0
/
SIGN IN