Update README.md (fix incorrect option name)

Fix `options.params` to `options.data` according to the source code (https://github.com/liziqiang/simple-jsonp-promise/blob/master/src/index.js#L22)
This commit is contained in:
TitanFighter 2020-10-19 16:21:54 +03:00 committed by GitHub
parent 6ef82540a5
commit fb1e5db79f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -11,7 +11,7 @@ yarn add simple-jsonp-promise
``` bash
import jsonp from 'simple-jsonp-promise'
let options = {
params:{
data: {
a : 1,
b : 2
},
@ -20,4 +20,4 @@ let options = {
timeout : 15000
}
let response = await jsonp('https://localhost/api.jsonp' , options);
```
```