axios-add-jsonp
Add a jsonp method to axios
Install
$ npm install axios-add-jsonp --save
Example
Unifies all requests
request request request
The form request is created, and the mode of usage remains unchanged
const request = request
Api
The usage method is basically the same as axios and jsonp, see axios and jsonp.
Format is as follows:
request.<method>(<url>, [<data>], [<config>]): Promise
Note: all methods are in this format, including GET, DELETE, HEAD, OPTIONS.
Promises
axios-add-jsonp depends on a native ES6 Promise implementation to be supported. If your environment doesn't support ES6 Promises, you can polyfill.
License
MIT