Serenity-JS/rest: Axios version issue when using an AxiosInstance
with latest axios version #1223
Closed
Description
I had to adjust the timeout of my axios
instance as mentioned in #1196 described in the second example here
To do so, I run npm install axios
which added the latest axios version, at the time of writing this was 0.27.4.
It results in this error:
Argument of type 'import("C:/.../e2e-serenityjs/node_modules/axios/index").AxiosInstance' is not assignable to parameter of type 'import("C:/.../e2e-serenityjs/node_modules/@serenity-js/rest/node_modules/axios/index").AxiosInstance'.
The types of 'defaults.method' are incompatible between these types.
Type 'string' is not assignable to type 'Method'.ts(2345)
@serenity-js/rest
still uses an axios version 0.21.4
I downgraded the axios package in my project to this version - and it was working again.
I did no further analysis so far, so I'm not sure if this is just because of the general version mismatch or if breaking changes where introduced in axios meanwhile.