From 8e49ff2ede931f65f69af5f733e7e5c5987adeb0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Liu=20=E5=AE=87=E9=98=B3?= Date: Mon, 28 Oct 2024 14:16:36 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=8B=E8=AF=95vercel=E5=8F=8D=E5=90=91?= =?UTF-8?q?=E4=BB=A3=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- vercel.json | 37 ++++++++++++++++++------------------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/vercel.json b/vercel.json index fcb3dac..8d8026f 100644 --- a/vercel.json +++ b/vercel.json @@ -1,21 +1,20 @@ { - "routes": [ - { - "src": "/api/(.*)", - "dest": "https://openapi.baidu.com/$1" - }, - { - "src": "/qiniu/(.*)", - "dest": "https://rsf.qiniuapi.com/$1" - }, - { - "src": "/ai/(.*)", - "dest": "https://spark-api-open.xf-yun.com/$1" - }, - { - "src": "/(.*)", - "dest": "/index.html" - } + "rewrites": [ + { + "source": "/api/:path*", + "destination": "https://openapi.baidu.com/:path*" + }, + { + "source": "/qiniu/:path*", + "destination": "https://rsf.qiniuapi.com/:path*" + }, + { + "source": "/ai/:path*", + "destination": "https://spark-api-open.xf-yun.com/:path*" + }, + { + "source": "/:path*", + "destination": "/index.html" + } ] - } - \ No newline at end of file +} \ No newline at end of file