Skip to content
wkh237 edited this page Oct 12, 2016 · 17 revisions

ios.openDocument(path:string, scheme:?string)

Open a file in UIDocumentInteractionController, this is the default document viewer of iOS, supports several kinds of files.

path:string

This is a required field, the path to the document.

scheme:?string

Optional field, a scheme like itms-books:// or so, throw error if the scheme is not supported. Notice that, if you're going to use extra scheme, you have to add an entry to LSApplicationQueriesSchemes to info.plist.

ios.previewDocument(path:string, scheme:?string)

Show actions menu for interact with the file.

<img src="https://raw.githubusercontent.com/wkh237/react-native-fetch-blob/master/img/action-menu.png" width="300/>

path:string

This is a required field, the path to the document.

scheme:?string

Optional field, a scheme like itms-books:// or so, throw error if the scheme is not supported. Notice that, if you're going to use extra scheme, you have to add an entry to LSApplicationQueriesSchemes to info.plist.

Clone this wiki locally