Commit 14808400 authored by JJ Kasper's avatar JJ Kasper Committed by Tim Neutkens

Add basePath to routes-manifest (#9875)

* Add basePath to routes-manifest

* Bump routes-manifest version

* Update tests for version bump
parent ae567bfc
......@@ -248,7 +248,8 @@ export default async function build(dir: string, conf = null): Promise<void> {
await fsWriteFile(
path.join(distDir, ROUTES_MANIFEST),
JSON.stringify({
version: 1,
version: 2,
basePath: config.experimental.basePath,
redirects: redirects.map(r => buildCustomRoute(r, true)),
rewrites: rewrites.map(r => buildCustomRoute(r)),
dynamicRoutes: getSortedRoutes(dynamicRoutes).map(page => ({
......
......@@ -198,7 +198,8 @@ const runTests = (isDev = false) => {
}
expect(manifest).toEqual({
version: 1,
version: 2,
basePath: '',
redirects: [
{
source: '/docs/router-status/:code',
......
......@@ -390,7 +390,8 @@ function runTests(dev) {
)
expect(manifest).toEqual({
version: 1,
version: 2,
basePath: '',
rewrites: [],
redirects: [],
dynamicRoutes: [
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment