Merge pull request #22 from Androz2091/patch-1

Update typings (errors on compilation)
This commit is contained in:
Wessel T
2020-01-25 19:03:31 +01:00
committed by GitHub

12
index.d.ts vendored
View File

@@ -32,8 +32,10 @@ declare module 'wumpfetch' {
timeoutTime: number; timeoutTime: number;
rHeaders: { [x: string]: string; } rHeaders: { [x: string]: string; }
coreOptions: { [x: string]: any }; coreOptions: { [x: string]: any };
body, json: any; body: any;
data, form: any; json: any;
data: any;
form: any;
} }
constructor(url: string | URL | ReqOptions, method?: string | ReqOptions); constructor(url: string | URL | ReqOptions, method?: string | ReqOptions);
public body(data: any, sendAs?: 'json' | 'form' | 'buffer'): this; public body(data: any, sendAs?: 'json' | 'form' | 'buffer'): this;
@@ -74,7 +76,9 @@ declare module 'wumpfetch' {
timeout?: number; timeout?: number;
headers?: { [x: string]: string }; headers?: { [x: string]: string };
coreOptions?: { [x: string]: any }; coreOptions?: { [x: string]: any };
body?, json?: any; body?: any;
data?, form?: any; json?: any;
data?: any;
form?: any;
} }
} }