mirror of
https://github.com/jekip/naive-ui-admin.git
synced 2026-02-04 13:42:27 +08:00
2.0.0
This commit is contained in:
19
types/config.d.ts
vendored
19
types/config.d.ts
vendored
@@ -52,8 +52,9 @@ export interface GlobConfig {
|
||||
shortName: string;
|
||||
urlPrefix?: string;
|
||||
uploadUrl?: string;
|
||||
prodMock: boolean;
|
||||
imgUrl?: string;
|
||||
useMock: boolean;
|
||||
fileUrl?: string;
|
||||
loggerMock: boolean;
|
||||
}
|
||||
|
||||
export interface GlobEnvConfig {
|
||||
@@ -63,12 +64,14 @@ export interface GlobEnvConfig {
|
||||
VITE_GLOB_API_URL: string;
|
||||
// 接口前缀
|
||||
VITE_GLOB_API_URL_PREFIX?: string;
|
||||
// Project abbreviation
|
||||
// 网站别名
|
||||
VITE_GLOB_APP_SHORT_NAME: string;
|
||||
// 图片上传地址
|
||||
// 文件上传地址
|
||||
VITE_GLOB_UPLOAD_URL?: string;
|
||||
//图片前缀地址
|
||||
VITE_GLOB_IMG_URL?: string;
|
||||
//生产环境开启mock
|
||||
VITE_GLOB_PROD_MOCK: boolean;
|
||||
// 文件前缀地址
|
||||
VITE_GLOB_FILE_URL?: string;
|
||||
// 开启 mock
|
||||
VITE_USE_MOCK: boolean;
|
||||
// 是否开启控制台打印 mock 请求信息
|
||||
VITE_LOGGER_MOCK: boolean;
|
||||
}
|
||||
|
||||
6
types/global.d.ts
vendored
6
types/global.d.ts
vendored
@@ -30,6 +30,12 @@ declare global {
|
||||
-readonly [P in keyof T]: T[P];
|
||||
};
|
||||
|
||||
declare interface InResult<T = any> {
|
||||
code: number;
|
||||
message: string;
|
||||
result: T;
|
||||
}
|
||||
|
||||
declare type Nullable<T> = T | null;
|
||||
declare type NonNullable<T> = T extends null | undefined ? never : T;
|
||||
declare type Recordable<T = any> = Record<string, T>;
|
||||
|
||||
7
types/images.d.ts
vendored
Normal file
7
types/images.d.ts
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
declare module '*.svg';
|
||||
declare module '*.png';
|
||||
declare module '*.jpg';
|
||||
declare module '*.jpeg';
|
||||
declare module '*.gif';
|
||||
declare module '*.bmp';
|
||||
declare module '*.tiff';
|
||||
Reference in New Issue
Block a user