import { ConfigEffect, LoadingState } from './interface'; import { Ref } from 'vue'; export declare type MakeEffect = CE extends (...payload: infer P) => infer R ? ((...payload: P) => R) & { loading: Ref; message: Ref; } : any; /** * @description: 把普通函数转化为observer的函数,对函数添加loading状态 * @param {F} function async函数,业务的load逻辑 * @param {shouldCheckResponse} boolean 是否检查res,设置为false就跳过检查来支持定时器等异步函数 * @return {ReturnType} */ export declare function makeEffect(fn: F, shouldCheckResponse?: boolean): MakeEffect;