浏览代码

Update README.md

wkh237 9 年前
父节点
当前提交
345a1f1473
共有 1 个文件被更改,包括 12 次插入18 次删除
  1. 12
    18
      README.md

+ 12
- 18
README.md 查看文件

524
 ```
524
 ```
525
 > If you're going to make downloaded file visible in Android `Downloads` app, please see [Show Downloaded File and Notification in Android Downloads App](#user-content-show-downloaded-file-and-notifiction-in-android-downloads-app).
525
 > If you're going to make downloaded file visible in Android `Downloads` app, please see [Show Downloaded File and Notification in Android Downloads App](#user-content-show-downloaded-file-and-notifiction-in-android-downloads-app).
526
 
526
 
527
-#### createFile(path, data, encoding):Promise
527
+### createFile(path, data, encoding):Promise
528
 
528
 
529
-##### path:`string`
529
+#### path:`string`
530
 The path which this new file will be created.
530
 The path which this new file will be created.
531
-##### data:`string` | `Array<number>`
531
+#### data:`string` | `Array<number>`
532
 Content of the new file, when `encoding` is `ascii`, this argument shoud be an array contains number 0~255.
532
 Content of the new file, when `encoding` is `ascii`, this argument shoud be an array contains number 0~255.
533
-##### encoding:`utf8` | `base64` | `ascii`
533
+#### encoding:`utf8` | `base64` | `ascii`
534
 Encoding of content.
534
 Encoding of content.
535
 
535
 
536
 the following expressions are equivalent.
536
 the following expressions are equivalent.
543
 fs.createFile(NEW_FILE_PATH, base64.encode('foo'), 'base64')
543
 fs.createFile(NEW_FILE_PATH, base64.encode('foo'), 'base64')
544
 ```
544
 ```
545
 
545
 
546
-#### writeStream(path:string, encoding:string, append:boolean):Promise<WriteStream>
546
+### writeStream(path:string, encoding:string, append:boolean):Promise<WriteStream>
547
 
547
 
548
-##### path:`string`
548
+#### path:`string`
549
 The path to the file the stream is writing to.
549
 The path to the file the stream is writing to.
550
-##### encoding:`utf8` | `base64` | `ascii`
550
+#### encoding:`utf8` | `base64` | `ascii`
551
 Encoding of input data.
551
 Encoding of input data.
552
-##### append:`boolean`(optional, default to `false`)
552
+#### append:`boolean`(optional, default to `false`)
553
 Will new data append after existing file or not.
553
 Will new data append after existing file or not.
554
 
554
 
555
 Calling `writeStream` method will returns a Promise, which resolves a `RNFetchBlobWriteSteam` instance when stream opened successfully.
555
 Calling `writeStream` method will returns a Promise, which resolves a `RNFetchBlobWriteSteam` instance when stream opened successfully.
679
 .catch((err) => { ... })
679
 .catch((err) => { ... })
680
 ```
680
 ```
681
 
681
 
682
-### Types
682
+## Types
683
 
683
 
684
 ---
684
 ---
685
 
685
 
686
-#### RNFetchBlobConfig
687
-
688
----
686
+### RNFetchBlobConfig
689
 
687
 
690
 A set of configurations that will be injected into a `fetch` method, with the following properties.
688
 A set of configurations that will be injected into a `fetch` method, with the following properties.
691
 
689
 
705
 
703
 
706
 ---
704
 ---
707
 
705
 
708
-#### RNFetchBlobResponse
709
-
710
----
706
+### RNFetchBlobResponse
711
 
707
 
712
 When `fetch` success, it resolve a `FetchBlobResponse` object as first argument. `FetchBlobResponse` object has the following methods (these method are synchronous, so you might take quite a performance impact if the file is big)
708
 When `fetch` success, it resolve a `FetchBlobResponse` object as first argument. `FetchBlobResponse` object has the following methods (these method are synchronous, so you might take quite a performance impact if the file is big)
713
 
709
 
729
 
725
 
730
 ---
726
 ---
731
 
727
 
732
-#### RNFetchBlobSession
733
-
734
----
728
+### RNFetchBlobSession
735
 
729
 
736
 A `session` is an object that helps you manage files. It simply main a list of file path and let you use `dispose()`to delete files in this session once and for all.
730
 A `session` is an object that helps you manage files. It simply main a list of file path and let you use `dispose()`to delete files in this session once and for all.
737
 
731