ShareMenu getInitialShare(callback: ShareCallback) : voidGets the shared item the app was opened with, if any. (share: ShareData?) => void
Result Type Description mimeType String The mime type of the shared data data String Either the shared text, or the location of the shared file extraData Object Can be null. Any optional extra data your Share Extension React View opened the app with.
addNewShareListener(callback: ShareCallback) : ShareListenerAdds a listener for receiving shared data from other apps. Call listener.remove() to remove it on unmount. (share: ShareData?) => void
Result Type Description mimeType String The mime type of the shared data data String Either the shared text, or the location of the shared file extraData Object Can be null. Any optional extra data your Share Extension React View opened the app with.
Method Params Description remove() None Removes a previously registered listener
ShareMenuReactView dismissExtension(error?: String) : voidDismisses the open Share Extension. Send an error message as a parameter to notify the system that the share action was canceled. Opens the App from the Share Extension.
continueInApp(extraData?: Object) : voidDefers the handling of this share action to the main App. You can send any object as a parameter if you need more context to handle the share in-app. data() : Promise<ShareData>Gets the shared data this Share Extension was opened with. Result Type Description mimeType String The mime type of the shared data data String Either the shared text, or the location of the shared file