mirror of
https://github.com/hanzoai/next.js.git
synced 2026-09-24 17:00:51 +00:00
This fixes the incorrect `/_next/data` URL being generated on client transition due to the `as` value passed to `getRouteInfo` having the `basePath` which is used while interpolating the values for dynamic routes, specifically root catch-all routes. A regression test has also been added to ensure this is working Closes: https://github.com/vercel/next.js/issues/15747
15 lines
209 B
JavaScript
15 lines
209 B
JavaScript
export default ({ url }) => (
|
|
<>
|
|
<h1>root catch-all</h1>
|
|
<p id="url">{url}</p>
|
|
</>
|
|
)
|
|
|
|
export const getServerSideProps = ({ req, res }) => {
|
|
return {
|
|
props: {
|
|
url: req.url,
|
|
},
|
|
}
|
|
}
|