Reputation: 2210
I am trying to run a completely offline bundle of my app only once to test if the microphone is working and failing to do so. I have read other threads and github issues but I have a rather weird setup:
My OSX machine (sierra) is running inside a VM (I do not have access to a Mac) so the iphone (5s running 10.2) and the OSX probably do not appear to be on the same network (because the host is connected to the same WIFI as the iphone but the VM is using NAT).
I can bundle correctly with react-native bundle --platform ios --dev false --entry-file index.ios.js --bundle-output ios/main.jsbundle
and
1) added the file to the project 2) set scheme target to release
the build success but I get after running
No script URL
is it possible to just put the main.jsbundle somehow in the iphone and just test it (it doesn't need any dev servers)? I do not care about debugging I just want to load it as you can do with an .apk in android. Why does it have to connect to any URL?
Upvotes: 1
Views: 3204
Reputation: 2210
The problem doesn't exist if I am using the package https://github.com/mcnamee/react-native-starter-app in my VM.
Upvotes: 0
Reputation: 420
As @vovkasm mentioned, it's worth checking whether the main.jsbundle
file is actually included in the compiled .app
. You can find it in the "Products" directory then right click on it in Finder and "Show Package Contents" the main.jsbundle
should be listed in there.
If not then you need to add main.jsbundle
to your Xcode project.
For me the bundle file was showing up in the project sidebar but wasn't actually added to the project properly.
Upvotes: 4