UNPKG

vue-hooks-plus

Version:
18 lines (17 loc) 738 B
import { UseRequestService, UseRequestOptions } from '../useRequest/types'; type FetchType<TData, TParams> = Record<string | number, { data: Readonly<TData> | undefined; params: TParams; loading: boolean; key: string | number; }>; type ParamsType<P> = P extends any[] ? any[] : any; declare function useFetchs<TData, TParams>(service: UseRequestService<TData, ParamsType<TParams>>, options: UseRequestOptions<TData, ParamsType<TParams>, any> & { manual: true; }, self: { fetchKey?: (...args: ParamsType<TParams>) => string; }): { fetchs: import("vue").Ref<FetchType<TData, TParams>, FetchType<TData, TParams>>; fetchRun: (...args: TParams extends any[] ? any[] : any) => void; }; export default useFetchs;