Files
weRequest/build/module/errorHandler.d.ts
Bing Liu e4ec9bc613 feat(types): 更新使用独立的微信小程序 types (#62)
* feat(types): 更新使用独立的微信小程序 types

* build: add package-lock.json

* feat: 由于当前仅修改依赖,不更新版本号
2023-03-16 20:25:14 +08:00

17 lines
875 B
TypeScript

/// <reference types="miniprogram-api-typings" />
import { IRequestOption, IUploadFileOption } from "../interface";
declare function systemError(obj: IRequestOption | IUploadFileOption, res: WechatMiniprogram.GeneralCallbackResult): void;
declare function logicError(obj: IRequestOption | IUploadFileOption, res: WechatMiniprogram.RequestSuccessCallbackResult | WechatMiniprogram.UploadFileSuccessCallbackResult): void;
declare function getErrorMsg(res: WechatMiniprogram.RequestSuccessCallbackResult | WechatMiniprogram.UploadFileSuccessCallbackResult): {
title: string;
content: string;
};
declare function doError(title: string, content: string, retry?: () => any): void;
declare const _default: {
systemError: typeof systemError;
logicError: typeof logicError;
doError: typeof doError;
getErrorMsg: typeof getErrorMsg;
};
export default _default;