2024-11-30 02:15:46 +08:00
|
|
|
export interface EnvConfig {
|
|
|
|
VITE_PORT: string;
|
|
|
|
VITE_ADDRESS: string;
|
|
|
|
VITE_API_BASE_URL: string;
|
|
|
|
VITE_API_USERNAME: string;
|
|
|
|
VITE_API_PASSWORD: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export const DEFAULT_CONFIG: EnvConfig = {
|
|
|
|
VITE_PORT: "22100",
|
|
|
|
VITE_ADDRESS: "localhost",
|
|
|
|
VITE_API_BASE_URL: "http://127.0.0.1:22000",
|
|
|
|
VITE_API_USERNAME: "",
|
|
|
|
VITE_API_PASSWORD: "",
|
2024-12-18 21:54:37 +08:00
|
|
|
};
|
2024-11-30 02:15:46 +08:00
|
|
|
|
|
|
|
// 扩展 ImportMeta 接口
|
|
|
|
declare global {
|
2024-12-04 02:35:06 +08:00
|
|
|
interface ImportMetaEnv extends EnvConfig {}
|
2024-11-30 02:15:46 +08:00
|
|
|
interface ImportMeta {
|
|
|
|
readonly env: ImportMetaEnv;
|
|
|
|
}
|
|
|
|
}
|