From 6f59cdbac99adfcda990b4106710337bb6994595 Mon Sep 17 00:00:00 2001 From: Philipp Loose <37411699+phloose@users.noreply.github.com> Date: Thu, 1 Dec 2022 19:36:42 +0100 Subject: [PATCH] refactor: add missing types for static AxiosError.from method (#4956) Co-authored-by: Jay --- index.d.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/index.d.ts b/index.d.ts index 82349769c7..4bcfa3dd0a 100644 --- a/index.d.ts +++ b/index.d.ts @@ -371,6 +371,14 @@ export class AxiosError extends Error { status?: number; toJSON: () => object; cause?: Error; + static from( + error: Error | unknown, + code?: string, + config?: AxiosRequestConfig, + request?: any, + response?: AxiosResponse, + customProps?: object, +): AxiosError; static readonly ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS"; static readonly ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE"; static readonly ERR_BAD_OPTION = "ERR_BAD_OPTION";