error: cannot find symbol MainApplicationReactNativeHost

Version SDK and react native platform that I used :

  1. SDK Version:45.0.0
  2. Platforms(Android/iOS/web/all):Android

Need help from you guys, I am new using expo. Currently I already have existing project using react-native CLI that created with “npx react-native init App” and want to add expo modules so I can install any other expo package, such as expo-updates but once did the installation expo for bare react native workflow and run command “npx install-expo-modules@latest” then try to running the app using react-native run android, I got some errors like this “cannot find symbol MainApplicationReactNativeHost”. Try to install it using manual step but still not working. Need some advice if I missed something, thanks in advance

Hey @allanjonna,

The process you seem to follow seems right. With latest SDK version and React Native version I’m able to successfully install expo modules in a react-native CLI app.

However, you filled the Expo SDK version to 45. Can you share details about what version of React Native your app is using? One reason for this error is that there might be a version incompatibility between the Expo SDK version installed and react-native version.

Hi @amanhimself thanks to reply, this issue was already solved by upgrading my react native app to version 0.68.0 which is already included a class 'MainApplicationReactNativeHost` it was required by expo configuration on android. But for now I got new error after create build apk then try to install and got crashed, but it was working on development mode

1 Like

Hi @allanjonna

Maybe see if expo-cli doctor complains about anything

1 Like

Hi @wodin , it was solved by upgrading my react native project to version 0.69.5. Thanks to reply

2 Likes

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.