mirror of
https://github.com/Tencent/tdesign-vue-next-starter.git
synced 2024-09-20 10:44:22 +08:00
Update vite.config.ts
与 react 模板统一配置。 https://github.com/Tencent/tdesign-react-starter/blob/develop/vite.config.js#L47-L57
This commit is contained in:
parent
07520a97e2
commit
89f8cbc1c7
|
@ -26,10 +26,15 @@ export default defineConfig({
|
||||||
],
|
],
|
||||||
|
|
||||||
server: {
|
server: {
|
||||||
port: 3002,
|
|
||||||
host: '0.0.0.0',
|
host: '0.0.0.0',
|
||||||
|
port: 3003,
|
||||||
proxy: {
|
proxy: {
|
||||||
'/api': 'http://127.0.0.1:3000/',
|
'/api': {
|
||||||
|
// 用于开发环境下的转发请求
|
||||||
|
// 更多请参考:https://vitejs.dev/config/#server-proxy
|
||||||
|
target: 'http://127.0.0.1:3000/',
|
||||||
|
changeOrigin: true,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue
Block a user