import type { AxiosRequestConfig, AxiosResponse } from 'axios'; type AxiosRequestConfigWithoutUrl = Omit; export type RemoteLoaderConfigType = 'json' | 'yaml' | 'toml' | 'yml'; export interface RemoteLoaderOptions extends AxiosRequestConfigWithoutUrl { /** * Config file type */ type?: ((response: any) => RemoteLoaderConfigType) | RemoteLoaderConfigType; /** * A function that maps http response body to corresponding config object */ mapResponse?: (config: any) => Promise | any; /** * A function that determines if the request should be retried */ shouldRetry?: (response: AxiosResponse) => boolean; /** * Number of retries to perform, defaults to 3 */ retries?: number; /** * Interval in milliseconds between each retry */ retryInterval?: number; } /** * Async loader loads configuration at remote endpoint. * * @param url Remote location of configuration * @param options options to configure async loader, support all `axios` options */ export declare const remoteLoader: (url: string, options?: RemoteLoaderOptions) => () => Promise; export {};