microapps-router-lib - Route `_next/data` requests for apps without basePath
Closed this issue · 1 comments
huntharo commented
Motivations
- Next.js apps with
basePath
set are complicated to get working correclty - Leaving
basePath
unset, but settingassetPrefix
should allow multi-page apps to be hosted on the same domain
Example Client-Side Nav Request
https://apps.ghpublic.pwrdrvr.com/_next/data/0.0.0-pr.37/nextjs-demo/posts/ssg-ssr.json?id=ssg-ssr
Acceptance Criteria
- Parse the app name after
_next/data
if it comes at the root of the deployment - Route requests using that app name
- Remove the
basePath
setting from the Next.js Demo app to test
huntharo commented
nextjs-demo without basePath: pwrdrvr/microapps-app-nextjs-demo#37