refactor(projects): 代码优化

This commit is contained in:
Soybean
2022-07-16 00:13:19 +08:00
parent 872bb84502
commit 6143605297
24 changed files with 107 additions and 104 deletions

View File

@ -2,7 +2,7 @@ import { getEnvConfig } from '~/.env-config';
import { createRequest } from './request';
const envConfig = getEnvConfig(import.meta.env);
const isHttpProxy = import.meta.env.VITE_HTTP_PROXY === '1';
const isHttpProxy = import.meta.env.VITE_HTTP_PROXY === 'Y';
export const request = createRequest({ baseURL: isHttpProxy ? envConfig.proxy : envConfig.url });