/**
* Create an S3FileFieldClient instance.
*
* @param options {S3FileFieldClientOptions} - A Object with all arguments.
* @param options.baseUrl - The absolute URL to the Django server.
* @param [options.apiConfig] - An axios configuration to use for Django API requests.
* Can be extracted from an existing axios instance via `.defaults`.
*/
From the code for the
S3FileFieldClient
constructor:On the latest version of axios,
axiosInstance.defaults
returns an object of typeAxiosDefaults
instead ofAxiosRequestConfig
as it did before. This is a new type introduced in https://github.com/axios/axios/commit/94a93447992392441f1928dffc9f10529ecec417#diff-7aa4473ede4abd9ec099e87fec67fd57afafaf39e05d493ab4533acc38547eb8L151-R171 that slightly differs fromAxiosRequestConfig
. SinceS3FileFieldClient
expectsapiConfig
to be of typeAxiosRequestConfig
, usingaxiosInstance.defaults
as the example specifies results in a type error.