feat(http-caching-proxy): replace request package with axios#4637
Conversation
f7d73b1 to
ecf41a7
Compare
ecf41a7 to
59de4bb
Compare
| url: | ||
| 'http://www.mocky.io/v2/5dade5e72d0000a542e4bd9c?mocky-delay=1000ms', | ||
| proxy: proxy.url, | ||
| resolveWithFullResponse: true, |
There was a problem hiding this comment.
resolveWithFullResponse is request's counter-part of Axios' validateStatus. Have you considered configuring validateStatus on a per-test basis, as we are doing with resolveWithFullResponse now?
|
Based on the investigation I did today, I am happy to choose Axios as our replacement for request 🎉 Let's improve implementation details now. Also, I am not confident that the switch from request to axios is fully backwards compatible in all edge cases, let's make this a semver-major change please. |
|
FYI: I opened a feature request in Axios to make their API closer to |
59de4bb to
a6bd41b
Compare
a6bd41b to
6a5d9c2
Compare
|
@bajtos PTAL. |
6a5d9c2 to
17e5bd0
Compare
bajtos
left a comment
There was a problem hiding this comment.
LGTM with few tiny comments to consider.
|
@raymondfeng As I commented elsewhere of before, I'd like us to release this change as a semver-major release. |
17e5bd0 to
8860fbb
Compare
… client BREAKING CHANGE: [axios](https://github.com/axios/) is now used as the http client package to replace [request](https://github.com/request/request) which is now deprecated.
8860fbb to
f3e55fa
Compare
This is part 2 to fix #2672
Checklist
👉 Read and sign the CLA (Contributor License Agreement) 👈
npm testpasses on your machinepackages/cliwere updatedexamples/*were updated👉 Check out how to submit a PR 👈