forked from vuejs/vue-cli
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: fix usage with https proxy by switching from axios to request (v…
…uejs#829) Closes vuejs#785 Axios has a [known issue](axios/axios#658) that causes requests to hang when accessing an HTTPS resource via a proxy served over HTTP. This changes out the axios dependency for the [request](https://github.com/request/request) library. In order to keep `async/await` conventions easy, I also dropped in the [request-promise-native](https://github.com/request/request-promise-native) dependency.
- Loading branch information
Showing
6 changed files
with
28 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
const request = require('request-promise-native') | ||
|
||
module.exports = { | ||
async get (uri) { | ||
const reqOpts = { | ||
method: 'GET', | ||
resolveWithFullResponse: true, | ||
json: true, | ||
uri | ||
} | ||
|
||
return request(reqOpts) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters