Add CORS headers for Vercel (#15)

This commit is contained in:
Matthias Kretschmann 2022-09-22 15:49:01 +01:00 committed by GitHub
parent bbe5ba820e
commit b5c88c3a26
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

13
vercel.json Normal file
View File

@ -0,0 +1,13 @@
{
"headers": [
{
"source": "/api/(.*)",
"headers": [
{ "key": "Access-Control-Allow-Credentials", "value": "true" },
{ "key": "Access-Control-Allow-Origin", "value": "*" },
{ "key": "Access-Control-Allow-Methods", "value": "GET,OPTIONS,PATCH,DELETE,POST,PUT" },
{ "key": "Access-Control-Allow-Headers", "value": "X-CSRF-Token, X-Requested-With, Accept, Accept-Version, Content-Length, Content-MD5, Content-Type, Date, X-Api-Version" }
]
}
]
}