umi 正式环境下 如何使用 proxy呢
#12706
-
UMI 可以在 .umirc.ts 中 配置 proxy 字段,来实现代理 {
"scripts": {
"dev": "umi dev",
"build": "umi build",
"postinstall": "umi setup",
"setup": "umi setup",
"start": "npm run dev"
}
} 但是似乎在默认的 package.json 中, 没有找到 类似 NextJs 类似的 正式运行(next start) 命令,只有在 正式环境下 似乎只能通过打包成 dist 后,通过 静态资源的形式 访问 |
Beta Was this translation helpful? Give feedback.
Answered by
soxft
Sep 24, 2024
Replies: 2 comments 1 reply
-
目前是 直接部署到 vercel的,也可以通过 vercel.json 或者 serverless function 来实现类似的 proxy |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
感谢