Skip to content

Commit

Permalink
Try manually redirecting trailing slash in Vercel to non-trailing in …
Browse files Browse the repository at this point in the history
…Next
  • Loading branch information
kmjennison committed Jul 20, 2020
1 parent 16f0d0c commit 34f6dbf
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 2 additions & 2 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,11 @@ if (process.env.USE_LOCAL_ENV_FILE === 'true') {

const nextConfig = {
// basePath: basePath,
exportTrailingSlash: false,
exportTrailingSlash: true,
// We also set the trailing slash preference in vercel.json.
// Trailing slash stable in v9.4.5-canary.41:
// https://github.com/vercel/next.js/releases/tag/v9.4.5-canary.41
trailingSlash: true,
// trailingSlash: true,
async redirects() {
return [
// This is for convenience in local development and when
Expand Down
3 changes: 3 additions & 0 deletions vercel.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
"alias": ["dev-tab-web"],
"cleanUrls": true,
"trailingSlash": true,
"rewrites": [
{ "source": "/(.*)/", "destination": "/$1" }
],
"headers": [
{
"source": "/newtab/service-worker.js",
Expand Down

0 comments on commit 34f6dbf

Please sign in to comment.