|
@@ -338,6 +338,17 @@ function isDir(path:string):Promise<bool, bool> {
|
338
|
338
|
|
339
|
339
|
}
|
340
|
340
|
|
|
341
|
+function df():Promise<{ free : number, total : number }> {
|
|
342
|
+ return new Promise((resolve, reject) => {
|
|
343
|
+ RNFetchBlob.df((err, stat) => {
|
|
344
|
+ if(err)
|
|
345
|
+ reject(err)
|
|
346
|
+ else
|
|
347
|
+ resolve(stat)
|
|
348
|
+ })
|
|
349
|
+ })
|
|
350
|
+}
|
|
351
|
+
|
341
|
352
|
export default {
|
342
|
353
|
RNFetchBlobSession,
|
343
|
354
|
unlink,
|
|
@@ -359,5 +370,6 @@ export default {
|
359
|
370
|
scanFile,
|
360
|
371
|
dirs,
|
361
|
372
|
slice,
|
362
|
|
- asset
|
|
373
|
+ asset,
|
|
374
|
+ df
|
363
|
375
|
}
|