瀏覽代碼

perf: 删除已废弃的 `$baseUrl `

xiaoxian521 2 年之前
父節點
當前提交
13a0db0180
共有 1 個文件被更改,包括 0 次插入3 次删除
  1. 0 3
      src/config/index.ts

+ 0 - 3
src/config/index.ts

@@ -31,7 +31,6 @@ const getConfig = (key?: string): ServerConfigs => {
 export const getServerConfig = async (app: App): Promise<undefined> => {
   app.config.globalProperties.$config = getConfig();
   return axios({
-    baseURL: "",
     method: "get",
     url: `${VITE_PUBLIC_PATH}serverConfig.json`
   })
@@ -44,8 +43,6 @@ export const getServerConfig = async (app: App): Promise<undefined> => {
         // 设置全局配置
         setConfig($config);
       }
-      // 设置全局baseURL
-      app.config.globalProperties.$baseUrl = $config.baseURL;
       return $config;
     })
     .catch(() => {