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

ios: No exact matches in call to instance method 'jsBundleURL' in ReactShareViewController.swift

Open xavax31 opened this issue 3 years ago • 5 comments
trafficstars

Hi, I tried to implement custom view following the doc, but I get error while building: Capture d’écran 2022-09-07 à 12 26 45 Capture d’écran 2022-09-07 à 12 26 56

It works running the example (after fix error by adding in podfile: 'useFlipper!({ 'Flipper-Folly' => '2.5.3', 'Flipper' => '0.87.0', 'Flipper-RSocket' => '1.3.1' }) My project targets ios 12 rather than ios 10 as in example, but if i change to 10, I get an error saying that RNShareMenu need ios 11. I use exactly same index.share.js and Share.js that the example.

Note: I'm on Macbook M1

Any idea?

xavax31 avatar Sep 07 '22 10:09 xavax31

Same problem appeared after switching from "react-native": "0.64.3" => "react-native": "0.69.5". Have you found a solution?

o-baranova avatar Sep 20 '22 14:09 o-baranova

Yes, after some research, I forked the package and made this change:
https://github.com/xavax31/react-native-share-menu/commit/20917a84d4dea48d14fd84902e61b01548e4861b

xavax31 avatar Sep 20 '22 15:09 xavax31

Same issue when implementing custom iOS share component.

Anybody found a solution that doesn't require a patch ?

BTW no reason to use a fork anymore now that patch-package exists

ice-cap0 avatar Oct 13 '22 13:10 ice-cap0

In the ReactShareViewController file change your code for this

return RCTBundleURLProvider.sharedSettings()?
      .jsBundleURL(forBundleRoot:"index.share")
      //.jsBundleURL(forBundleRoot: "index.share", fallbackResource: nil)

JesusTectronic avatar Dec 28 '22 19:12 JesusTectronic

Removing ? worked for me