-
Notifications
You must be signed in to change notification settings - Fork 87
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
【refactor】Refactoring Request with Axios #65
Comments
@Molunerfinn So all the uploaders will have to change their implementation? |
Yes. In Before v1.5.0, PicGo-Core will provide a way to install a specific version of plugins. |
@Molunerfinn This is very nice~ |
@Molunerfinn At the present, PicGo CLI ( |
yes we can use axios |
The next alpha version of PicGo-Core will change request to axios. For plugin developers:
const res = await ctx.request({
// other options
resolveWithFullResponse: true
})
console.log(res) // { status, data, headers, config, request }
const res2 = await ctx.request({
// other options
})
console.log(res2) // { ...data } |
v1.5.0-alpha.9 is release |
Since the package request was deprecated, PicGo-Core will replace it with axios which is active and maintained.
The timeline is the following:
request
withaxios
, but the API exposed to the outside world is still consistent. You can still usectx.Request.request
. However, it will be warned withdeprecated
. The new api isctx.request
. And you can still use both the old requestoptions
& the new axiosoptions
for requesting.ctx.request
is OK, though therequest
lib will be changed toaxios
. And you can't usectx.Request.request
anymore.The text was updated successfully, but these errors were encountered: