cross-jsonp

1.0.0 • Public • Published

jsonp

Can be used to solve the mainstream browser cross domain data access problems

how to use it

npm install cross-jsonp --save-dev
import getJsonpData from 'cross-jsonp';
getJsonpData(url,data).then(response=>{
    console.log(response);
})

params

name description
url (String) url to fetch
data name of the query string parameter to
timeout (Number) how long after a timeout error is emitted. 0 to disable (defaults to 10000)
callbackName (String) name of the global callback functions that handle jsonp responses

Readme

Keywords

Package Sidebar

Install

npm i cross-jsonp

Weekly Downloads

2

Version

1.0.0

License

MIT

Last publish

Collaborators

  • notlaughtingme