|
@@ -204,7 +204,7 @@ RNFetchBlob
|
204
|
204
|
fileCache : true,
|
205
|
205
|
})
|
206
|
206
|
.fetch('GET', 'http://www.example.com/file/example.zip', {
|
207
|
|
- some headers ..
|
|
207
|
+ //some headers ..
|
208
|
208
|
})
|
209
|
209
|
.then((res) => {
|
210
|
210
|
// the temp file path
|
|
@@ -224,7 +224,7 @@ RNFetchBlob
|
224
|
224
|
appendExt : 'png'
|
225
|
225
|
})
|
226
|
226
|
.fetch('GET', 'http://www.example.com/file/example.zip', {
|
227
|
|
- some headers ..
|
|
227
|
+ //some headers ..
|
228
|
228
|
})
|
229
|
229
|
.then((res) => {
|
230
|
230
|
// the temp file path with file extension `png`
|
|
@@ -387,7 +387,7 @@ In `version >= 0.4.2` it is possible to know the upload/download progress. After
|
387
|
387
|
|
388
|
388
|
```js
|
389
|
389
|
RNFetchBlob.fetch('POST', 'http://www.example.com/upload', {
|
390
|
|
- ... some headers,
|
|
390
|
+ //... some headers,
|
391
|
391
|
'Content-Type' : 'octet-stream'
|
392
|
392
|
}, base64DataString)
|
393
|
393
|
// listen to upload progress event
|
|
@@ -411,7 +411,7 @@ In `0.9.6`, you can specify an object as first argument which contains `count` a
|
411
|
411
|
|
412
|
412
|
```js
|
413
|
413
|
RNFetchBlob.fetch('POST', 'http://www.example.com/upload', {
|
414
|
|
- ... some headers,
|
|
414
|
+ //... some headers,
|
415
|
415
|
'Content-Type' : 'octet-stream'
|
416
|
416
|
}, base64DataString)
|
417
|
417
|
// listen to upload progress event, emit every 250ms
|
|
@@ -491,7 +491,7 @@ When using DownloadManager, `fileCache` and `path` properties in `config` will n
|
491
|
491
|
```js
|
492
|
492
|
RNFetchBlob
|
493
|
493
|
.config({
|
494
|
|
- addAdnroidDownloads : {
|
|
494
|
+ addAndroidDownloads : {
|
495
|
495
|
useDownloadManager : true, // <-- this is the only thing required
|
496
|
496
|
// Optional, override notification setting (default to true)
|
497
|
497
|
notification : false,
|
|
@@ -530,7 +530,7 @@ RNFetchBlob.config({
|
530
|
530
|
description : 'An image file.',
|
531
|
531
|
mime : 'image/png',
|
532
|
532
|
// Make the file scannable by media scanner
|
533
|
|
- meidaScannable : true,
|
|
533
|
+ mediaScannable : true,
|
534
|
534
|
}
|
535
|
535
|
})
|
536
|
536
|
.fetch('GET', 'http://example.com/image1.png')
|