react-native-share-menu icon indicating copy to clipboard operation
react-native-share-menu copied to clipboard

Share doesn't redirect to app (iOS)

Open davidsalib opened this issue 3 years ago • 12 comments

I've tried with both the default Share popup, and a custom popup. In both cases, when I press "Post" or "Continue to App", the main app doesn't launch.

I verified that the HostAppBundleIdentifier and HostAppURLScheme are set properly in both the App and Share Extension Info.plist respectively.

Any ideas/advice is much appreciated!

davidsalib avatar Oct 20 '21 22:10 davidsalib

Same here. More instructions on this would be much appreciated.

ghost avatar Oct 22 '21 13:10 ghost

@davidsalib I noticed that on iOS for some types of files it does NOT launch the app at all. But when sharing an image for example it works. Did you manage to get it working with Android?

ghost avatar Oct 22 '21 22:10 ghost

The instructions seem to be wrong and at least on iOS, the HostAppURLScheme requires the name to end with ://, e.g. if your app package is called myapp, then you need to use myapp://

kubik369 avatar Nov 08 '21 17:11 kubik369

@kubik369 Your solution works for me, thanks! BTW, do you know how could we directly share text to app without pressing "Post" or "Continue to App" in iOS ?

Hope to hear your expertise.

robbiedood avatar Jan 12 '22 07:01 robbiedood

@lukelu0520 Hi, you should be able to open the app immediately when the user selects it in the share menu, you don't need to wait for any press as far as I know :)

kubik369 avatar Jan 12 '22 09:01 kubik369

@kubik369 Thanks for your reply:) I was wondering if you follow the example folder or the iOS instruction. Seems like there is discrepancy between them.

ps: Android works great, be able to open the app immediately when the user selects it in the share menu, but iOS has the issue.

robbiedood avatar Jan 12 '22 18:01 robbiedood

@kubik369 hi sir, kindly explain i am trying to send extraData in my app from share by using continueInApp in IOS but i can't receive that data in my app. can u please help. @lukelu0520 @gilsonviana-modus @davidsalib

ShareMenuReactView.data().then(item => {
     ShareMenuReactView.continueInApp({
       continueInApp: true,
       data: item.data[0].data,
       mimeType: item.data[0].mimeType,
     });
   
   });

asadd-irfan avatar Sep 01 '22 08:09 asadd-irfan

@asadd-irfan same problem. Are you have solution for this?

lac96it avatar Nov 11 '22 14:11 lac96it

@kubik369 have you solved it for you, to skip dialog on iOS ?

roman-myshchyshyn avatar May 05 '23 13:05 roman-myshchyshyn

@roman-myshchyshyn I wasn't able to get rid of the modal popping up for a split second (although I think it would be possible with some objective C/Swift skills). We have it currently set up so that continueInApp gets called immediately and that goes into the app :)

kubik369 avatar May 05 '23 14:05 kubik369

@kubik369 Can you please share the steps on how you did that? Thanks!

teja2495 avatar Jul 24 '23 20:07 teja2495