We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4bf745d commit cfced96Copy full SHA for cfced96
src/gatsby-node.js
@@ -50,13 +50,18 @@ exports.onPostBuild = async (
50
}
51
)
52
53
- // return {
54
- // fromPath: page.matchPath,
55
- // toPath: page.path,
56
- // }
+ if (
+ pluginOptions.generateMatchPathRewrites &&
+ page.matchPath !== page.path
+ ) {
57
+ rewrites.push({
58
+ fromPath: page.matchPath,
59
+ toPath: page.path,
60
+ })
61
+ }
62
})
63
reporter.info(
- `[gatsby-plugin-netlify] Creating ${count} SSR redirect${
64
+ `[gatsby-plugin-netlify] Created ${count} SSR redirect${
65
count === 1 ? `` : `s`
66
}...`
67
0 commit comments