forked from vercel/next.js
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Verify that dataroutes work correctly with assetPrefix (vercel#15309)
Fixes vercel#12046 Fixes vercel#11992 Closes vercel#13456
- Loading branch information
Showing
4 changed files
with
88 additions
and
8 deletions.
There are no files selected for viewing
14 changes: 14 additions & 0 deletions
14
test/integration/absolute-assetprefix/pages/gsp-fallback/[slug].js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
export async function getStaticPaths() { | ||
return { | ||
paths: [{ params: { slug: 'prerendered' } }], | ||
fallback: true, | ||
} | ||
} | ||
|
||
export async function getStaticProps({ params }) { | ||
return { props: { slug: params.slug } } | ||
} | ||
|
||
export default function GspPage({ slug }) { | ||
return <div id="prop">{slug}</div> | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
export async function getServerSideProps({ query }) { | ||
return { props: { prop: query.prop } } | ||
} | ||
|
||
export default function GspPage({ prop }) { | ||
return <div id="prop">{prop}</div> | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters