Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined is not an object (evaluating NativeModules.SegmentedControlManager.ComponentHeight #1272

Closed
jessepollak opened this issue May 14, 2015 · 7 comments
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@jessepollak
Copy link

I accidentally ran npm install react-native inside of the React app folder. Since then, I've been getting the above error and can't figure out how to solve the issue.

Any ideas?

screenshot 2015-05-13 21 51 55

@wim82
Copy link

wim82 commented May 14, 2015

Somehow i've hit the same issue. But by restarting the packager.. after doing some updates.

@wim82
Copy link

wim82 commented May 14, 2015

More info: it happened after setting "latest" as the version for react-native. When i set it to 0.4.1 everything is fine again.

@esauter5
Copy link
Contributor

I got this issue as well. It happened after I pulled the latest from master to my fork and then tried using that local version of react-native in a react-native project.

@jessepollak
Copy link
Author

Downgrading to 0.4.1 fixed it for me as well.

@brentvatne
Copy link
Collaborator

Does this happen for all of you if you clone the repo and run the UIExplorer app?

@brentvatne
Copy link
Collaborator

Tested this on master in UIExplorer and it works fine. Make sure you have all of these files included in your Libraries/React.xcodeproj

react-native/React/Views/RCTSegmentedControl.h
react-native/React/Views/RCTSegmentedControl.m 
react-native/React/Views/RCTSegmentedControlManager.h
react-native/React/Views/RCTSegmentedControlManager.m

@jessepollak
Copy link
Author

Tried upgrading to 0.4.4 and the issue persisted. Checked if I had those files and I didn't. Looked at my Podfile.lock and it had React at 0.4.1. Changed my Podfile from pod 'React' to pod 'React', '~> 0.4.4' and it worked. I guess it's not surprising that we need to keep the Pod and JS in sync, sorry about the trouble. Hope this helps someone else!

@facebook facebook locked as resolved and limited conversation to collaborators May 29, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jul 22, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

5 participants