react-native: main.jsbundle does not exist.
error: File /Users/.../Library/Developer/Xcode/DerivedData/...-aokvzxgftaspzkbofcoasbicvvvy/Build/Intermediates.noindex/ArchiveIntermediates/.../BuildProductsPath/Release-iphoneos/....app/main.jsbundle does not exist. This must be a bug with
Add the following line to your package.json file under the “scripts” and replace yourAppName
with a proper name :
"bundle:ios": "node ./node_modules/react-native/local-cli/cli.js bundle --platform ios --entry-file index.js --bundle-output ios/yourAppName/main.jsbundle --dev=false --verbose",
Now you can run the command to generate main.jsbundle:
npx yarn bundle:ios
Open the Xcode -> Select project target -> add main.jsbundle
to Copy Bundle Resource
in Build Phases