Skip to content

Commit 698d993

Browse files
committed
Allow different types of for Data for axios request config
1 parent 75c63d6 commit 698d993

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

types/Http.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { ReadStream } from 'fs';
2+
import { Stream } from 'stream';
23

34
export type Data = {
45
// eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -15,7 +16,14 @@ export type AxiosConfigOptions = {
1516
env?: string;
1617
localHostOverride?: boolean;
1718
params?: QueryParams;
18-
data?: Data;
19+
data?:
20+
| Data
21+
| string
22+
| ArrayBuffer
23+
| ArrayBufferView
24+
| URLSearchParams
25+
| Stream
26+
| Buffer;
1927
resolveWithFullResponse?: boolean;
2028
timeout?: number;
2129
headers?: Data;

0 commit comments

Comments
 (0)