2
0
mirror of https://github.com/tenrok/axios.git synced 2026-06-17 19:21:29 +03:00

feat: export getAdapter function (#5324)

This commit is contained in:
夜葬
2023-08-27 01:42:25 +08:00
committed by GitHub
parent 9a414bb6c8
commit ca73eb878d
7 changed files with 42 additions and 0 deletions
Vendored
+3
View File
@@ -512,6 +512,8 @@ export interface GenericHTMLFormElement {
submit(): void;
}
export function getAdapter(adapters: AxiosAdapterConfig | AxiosAdapterConfig[] | undefined): AxiosAdapter;
export function toFormData(sourceObj: object, targetFormData?: GenericFormData, options?: FormSerializerOptions): GenericFormData;
export function formToJSON(form: GenericFormData|GenericHTMLFormElement): object;
@@ -538,6 +540,7 @@ export interface AxiosStatic extends AxiosInstance {
isAxiosError: typeof isAxiosError;
toFormData: typeof toFormData;
formToJSON: typeof formToJSON;
getAdapter: typeof getAdapter;
CanceledError: typeof CanceledError;
AxiosHeaders: typeof AxiosHeaders;
}