React-native-share: Possible Unhandled Promise Rejection (id: 0)

Created on 7 Sep 2016  路  4Comments  路  Source: react-native-share/react-native-share

I'm trying to implement the simple sharing

import Share, {ShareSheet, Button} from 'react-native-share';

<TouchableHighlight onPress={() => {
     Share.open({
        title: "React Native",
        message: "Hola mundo",
        url: "http://facebook.github.io/react-native/"
      })
}}>
      <Text> Share </Text>
</TouchableHighlight>

But I got this error:

09-07 11:07:45.829 3037 5393 W ReactNativeJS: Possible Unhandled Promise Rejection (id: 0):
09-07 11:07:45.829 3037 5393 W ReactNativeJS: undefined is not an object (evaluating '_reactNative.NativeModules.RNShare.open')

Any advice ?

Most helpful comment

I am having this problem and I have including it into MainApplication.java

All 4 comments

Don't worry my fault, I didn't add this new RNSharePackage() on MainApplication.java.

Thanks!

I am having this problem and I have including it into MainApplication.java

I'm having this issue too but on iOS. What did you guys do to solve it?

Has anyone figured this out?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

vikjovanov picture vikjovanov  路  3Comments

fredrik-jarnbrost picture fredrik-jarnbrost  路  3Comments

Rickkorsten picture Rickkorsten  路  3Comments

tomtargosz picture tomtargosz  路  3Comments

kunalnagar picture kunalnagar  路  3Comments