Skip to content

Commit

Permalink
Adding better 'responseType' and 'method' type definitions by using a…
Browse files Browse the repository at this point in the history
… string literal union type of possible values (#1148)
  • Loading branch information
Fitzpasd authored and JustinBeckwith committed Apr 8, 2018
1 parent 8e3b50c commit dd16944
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.d.ts
Expand Up @@ -22,7 +22,7 @@ export interface AxiosProxyConfig {

export interface AxiosRequestConfig {
url?: string;
method?: string;
method?: 'get' | 'delete' | 'head' | 'options' | 'post' | 'put' | 'patch';
baseURL?: string;
transformRequest?: AxiosTransformer | AxiosTransformer[];
transformResponse?: AxiosTransformer | AxiosTransformer[];
Expand All @@ -34,7 +34,7 @@ export interface AxiosRequestConfig {
withCredentials?: boolean;
adapter?: AxiosAdapter;
auth?: AxiosBasicCredentials;
responseType?: string;
responseType?: 'arraybuffer' | 'blob' | 'document' | 'json' | 'text' | 'stream';
xsrfCookieName?: string;
xsrfHeaderName?: string;
onUploadProgress?: (progressEvent: any) => void;
Expand Down

0 comments on commit dd16944

Please sign in to comment.