plaid / plaid-node

Node bindings for Plaid
https://plaid.com/docs
MIT License
525 stars 173 forks source link

Axios Dependency Upgrade from 0.21.4 to Latest #595

Closed abcalderon3 closed 1 year ago

abcalderon3 commented 1 year ago

Hello! Would it be possible to upgrade the Axios dependency from the pinned 0.21.4 to a latest version?


As context for the ask, I'm trying to pass a custom Axios Instance into the PlaidApi constructor, in order to have an Axios intercepter attached to centralize the error handling and leverage my framework's (NestJS) error handling.

const plaidApi = new PlaidApi(configuration, undefined, customAxiosInstance)

The old version of Axios in the underlying Plaid library is causing the following type incompatibility error with a later version of Axios (currently running 1.3.4).

Argument of type 'import("path/to/my/node_modules/axios/index").AxiosInstance' is not assignable to parameter of type 'import("path/to/my/node_modules/plaid/node_modules/axios/index").AxiosInstance'.
  The types of 'defaults.method' are incompatible between these types.
    Type 'string | undefined' is not assignable to type 'Method | undefined'.
      Type 'string' is not assignable to type 'Method | undefined'.
cgfarmer4 commented 1 year ago

We have updated to 1.5.0. Thanks for raising this!