mirror of
https://github.com/tenrok/axios.git
synced 2026-06-17 19:21:29 +03:00
feat(types): extend AxiosResponse interface to include custom headers type (#6782)
This commit is contained in:
Vendored
+2
-2
@@ -393,11 +393,11 @@ export interface CreateAxiosDefaults<D = any> extends Omit<AxiosRequestConfig<D>
|
||||
headers?: RawAxiosRequestHeaders | AxiosHeaders | Partial<HeadersDefaults>;
|
||||
}
|
||||
|
||||
export interface AxiosResponse<T = any, D = any> {
|
||||
export interface AxiosResponse<T = any, D = any, H = {}> {
|
||||
data: T;
|
||||
status: number;
|
||||
statusText: string;
|
||||
headers: RawAxiosResponseHeaders | AxiosResponseHeaders;
|
||||
headers: H & RawAxiosResponseHeaders | AxiosResponseHeaders;
|
||||
config: InternalAxiosRequestConfig<D>;
|
||||
request?: any;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user