spencercarli / react-native-meteor-boilerplate

MIT License
628 stars 139 forks source link

App crashing when run on Android Simulator & Device #48

Closed jasonnathan closed 8 years ago

jasonnathan commented 8 years ago

I must apologise for the lack of detailed info. Here are my steps to reproduce the issue

macOS Sierra v 10.12 beta

1) Ran npm install in the RNApp folder. I still get npm warnings but I've ignored them as suggested in other threads

npm WARN eslint-config-airbnb@9.0.1 requires a peer of eslint@^2.9.0 but none was installed.
npm WARN eslint-config-airbnb@9.0.1 requires a peer of eslint-plugin-jsx-a11y@^1.2.0 but none was installed.
npm WARN eslint-config-airbnb-base@3.0.1 requires a peer of eslint@^2.9.0 but none was installed.

2) Ran the same npm install in the MeteorApp folder I also ran meteor update to update the Meteor patch to 1.14.01 Meteor runs successfully. I can access the webpage via http://MY-MACS-IP:3000.

3) Updated the METEOR_URL in config/settings to reflect the IP as suggested in the docs.

I keep getting a:

Unfortunately, RNApp has stopped

dialog when I run on both the simulator and the device. It crashes and I don't know where to begin debugging (Most tutorials assume the App is running)

nilsonivano commented 8 years ago

Same bug here. Trying to run with default android simulator.

nilsonivano commented 8 years ago

@jasonnathan just followed @abelovic steps mentioned on #41 and that solved my problem. Try to follow the steps below

Delete the RNApp folder. Note: I'm guessing if we can figure out which files are incorrect we probably can just fix those instead of deleting the entire RNApp folder. This was just easier/faster for me. Run react-native init RNApp from the root of the project which will create an RNApp folder at the same level as MeteorApp folder Copy the app folder, index.android.js, index.ios.js, and package.json from the boilerplate back into your new RNApp folder Run npm install Make sure you configure the RNApp/app/config/settings.js as per the boilerplate documentation Run meteor in a different command/bash shell from the MeteorApp folder Start your android emulator Run react-native run-android I am running on Windows 10 and this works for me on all emulators i.e. GenyMotion, Android Studio etc... with no errors :)

jasonnathan commented 8 years ago

Thanks @nilsonivano. Will try as soon as I am able

jasonnathan commented 8 years ago

Followed the steps above - didn't work the first time, but ran after that. Thanks @nilsonivano!