Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

fix: fix path rewriting for local dev for docs pages

TzeYiing3e79b80d323c
diff --git a/apps/www/.env b/apps/www/.env
index 3f035873262..288fff589fa 100644
--- a/apps/www/.env
+++ b/apps/www/.env
@@ -5,7 +5,7 @@
# Replace this URL with the URL of your blog app
NEXT_PUBLIC_URL="https://localhost:3000"
-NEXT_PUBLIC_DOCS_URL="http://localhost:3005"
+NEXT_PUBLIC_DOCS_URL="http://localhost:3001"
NEXT_PUBLIC_STUDIO_URL="https://localhost:8082"
NEXT_PUBLIC_LAUNCHWEEKSITE_URL="https://localhost:3008"
NEXT_PUBLIC_REFERENCE_DOCS_URL="https://localhost:3010"
diff --git a/apps/www/lib/rewrites.js b/apps/www/lib/rewrites.js
index b5f9efbea19..f8b13dab0dd 100644
--- a/apps/www/lib/rewrites.js
+++ b/apps/www/lib/rewrites.js
@@ -1,21 +1,21 @@
module.exports = [
- {
- source: '/:path*',
- destination: `/:path*`,
- },
+ // {
+ // source: '/:path*',
+ // destination: `/:path*`,
+ // },
{
source: '/docs',
- destination: `${process.env.NEXT_PUBLIC_DOCS_URL}`,
+ destination: `${process.env.NEXT_PUBLIC_DOCS_URL}/docs`,
},
{
// redirect /docs/
// trailing slash caused by docusaurus issue with multizone
source: '/docs/',
- destination: `${process.env.NEXT_PUBLIC_DOCS_URL}`,
+ destination: `${process.env.NEXT_PUBLIC_DOCS_URL}/docs/`,
},
{
source: '/docs/:path*',
- destination: `${process.env.NEXT_PUBLIC_DOCS_URL}/:path*`,
+ destination: `${process.env.NEXT_PUBLIC_DOCS_URL}/docs/:path*`,
},
// rewrite to keep existing ticket urls working
{