Closed
Labels
StaleThere has been a lack of activity on this issue and it may be closed soon.There has been a lack of activity on this issue and it may be closed soon.
Description
Is this a bug report?
Yes
Have you read the Contributing Guidelines?
Yes
Environment
Environment:
OS: macOS High Sierra 10.13.1
Node: 8.9.1
Yarn: 1.3.2
npm: 5.5.1
Watchman: 4.9.0
Xcode: Xcode 9.1 Build version 9B55
Android Studio: 2.3 AI-162.4069837
Packages: (wanted => installed)
react: 16.0.0 => 16.0.0
react-native: 0.50.4 => 0.50.4
Steps to Reproduce
- In the
onPresshandler of a touchable component, callShare.share(...).then(...).catch((error) => console.log(error)); - Check JS console logs
Expected Behavior
The Share API should not error.
Actual Behavior
The Share API errors:
TypeError: Cannot read property 'showShareActionSheetWithOptions' of undefined
at Share.js:83
at tryCallTwo (core.js:45)
at doResolve (core.js:200)
at new Promise (core.js:66)
at Function.share (Share.js:82)
at ActivityGlobal._shareMessage (activityGlobal.js:76)
at ActivityGlobal.proxiedMethod (createPrototypeProxy.js:44)
at Object.touchableHandlePress (TouchableHighlight.js:285)
at Object._performSideEffectsForTransition (Touchable.js:746)
at Object._receiveSignal (Touchable.js:664)
The error is on this line: https://github.com/facebook/react-native/blob/eb0d6470e54663538610a70ab0bae9847eb33673/Libraries/Share/Share.js#L89
ActionSheetManager is undefined here.
Reproducible Demo
See steps above.
Reacted by Temitope
Metadata
Metadata
Assignees
Labels
StaleThere has been a lack of activity on this issue and it may be closed soon.There has been a lack of activity on this issue and it may be closed soon.
Activity
joncursi commentedon Nov 30, 2017
"Fixed" via #4042 (comment) - I think this tidbit of information should be in the Share API documentation
stale commentedon Jan 29, 2018
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. If you think this issue should definitely remain open, please let us know why. Thank you for your contributions.