I’m on the managed workflow. Recently migrated from expo build to EAS build and builds are working on Android but not iOS. iOS fails on the “Run fastlane” step, resulting in some Xcode logs.
Error: @build-script-error-begin
Error loading application entrypoint. If your entrypoint is not index.js, please set ENTRY_FILE environment variable with your app entrypoint.
@build-script-error-end
However my project’s entrypoint is index.js. And given that the Android build works fine, I’m not sure why iOS is failing. Any ideas as to what could be going wrong?
This is what Keith linked to in his comment above, but the link was changed, so his doesn’t currently take you to the correct place on that page.
So if you’re on the managed workflow, your package.json probably has a line that looks like this:
"main": "node_modules/expo/AppEntry.js",
If you’re on the bare workflow, this probably needs to be:
"main": "index.js",
Although, I’ve just run npx expo prebuild in a new test app and it did not make the above change as it used to. So I’m not sure the above documentation is true anymore.
Could you give some more information about what’s going wrong for you?
EDIT: The above is slightly out of date. It’s still valid for Expo SDK <= 48.
expo export:embedhas replaced the@react-native-community/clibundle command in the “Bundle React Native code and images” build phase. This has allowed us to add support for custom entry points — you can change "main" in package.json to point to any source file (be sure to use registerRootComponent in the new entry file, if you aren’t using Expo Router).