Allow API routes in vercel.json rewrites
cgen-80844d0e0e4842c6b4539fc30fbe3380
This commit is contained in:
parent
f810bdcba1
commit
6db4218ff6
1 changed files with 4 additions and 1 deletions
|
|
@ -2,7 +2,10 @@
|
||||||
"version": 2,
|
"version": 2,
|
||||||
"buildCommand": "npm ci && npm run build",
|
"buildCommand": "npm ci && npm run build",
|
||||||
"outputDirectory": "dist/spa",
|
"outputDirectory": "dist/spa",
|
||||||
"rewrites": [{ "source": "/(.*)", "destination": "/index.html" }],
|
"rewrites": [
|
||||||
|
{ "source": "/api/(.*)", "destination": "/api/$1" },
|
||||||
|
{ "source": "/(.*)", "destination": "/index.html" }
|
||||||
|
],
|
||||||
"headers": [
|
"headers": [
|
||||||
{
|
{
|
||||||
"source": "/assets/(.*)",
|
"source": "/assets/(.*)",
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue