Error in new version v1.21.1 -> new MockAdapter(axios)
henriqueholtz opened this issue · comments
Henrique Holtz commented
Error at new version: v1.21.1
Code:
import axios from 'axios';
import MockAdapter from 'axios-mock-adapter';
var mock = new MockAdapter(axios);
My package.json:
[...]
"axios": "^0.27.2",
"axios-mock-adapter": "^1.21.1",
[...]
My project: https://github.com/SharebookBR/sharebook-frontend-next
Colin Timmermans commented
Can you confirm that it does work on v1.20?
The place where the error occurs hasn't changed recently and would indicate there's something wrong with your axios setup (axios.defaults
being undefined).
Henrique Holtz commented
Colin Timmermans commented
I'm pretty sure this is an error with your TypeScript setup and not with this library, so I'll close the issue for now. Please reopen it if you're able to reproduce it in a test.