Skip to content

Commit 4a2ab79

Browse files
msujawsclaude
andcommitted
fix: remove conflicting API rewrite rule in vercel.json
The rewrite rule for /api/* was intercepting requests before they could reach the serverless functions, causing Vercel to return 404 HTML pages instead of proxying to Bugzilla. Changed to use a negative lookahead so only non-API routes are rewritten to index.html for the SPA. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 13d8204 commit 4a2ab79

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

vercel.json

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,7 @@
22
"buildCommand": "npm run build",
33
"outputDirectory": "dist",
44
"framework": "vite",
5-
"rewrites": [
6-
{ "source": "/api/(.*)", "destination": "/api/$1" },
7-
{ "source": "/(.*)", "destination": "/index.html" }
8-
],
5+
"rewrites": [{ "source": "/((?!api/).*)", "destination": "/index.html" }],
96
"headers": [
107
{
118
"source": "/(.*)",

0 commit comments

Comments
 (0)