Create-react-native-app: How to completely remove Expo from the projects?

Created on 17 Apr 2017  Â·  8Comments  Â·  Source: expo/create-react-native-app

Hi, I was trying out expo but so far it has given me more headaches than actual benefits - I say not wanting to offend at all since it was probably me that didn't know to use it.

Now I would really appreciate a step-by-step on how to remove it from both iOS and android projects.

Thanks!

ps: I also posted the issue here for reference.

Most helpful comment

Hello!

This is included in the documentation under "Ejecting".

After you do that, just remove all references to expo in your JS code (like you would with any JavaScript package) - there are no references to it in a new CRNA project, so if you didn't use it in your code then you're good to go.

Alternatively, you could create a new project with react-native init and copy and paste your JS files into it. If you have already ejected to ExpoKit, I recommend taking this approach or reverting back in git to your most recent commit pre-ejecting and eject directly to React Native instead.

We would appreciate if you could write us with more details on exactly what issues you had with Expo! You can reach us at [email protected]. Sorry it didn't work out for you!

Best,
Brent

All 8 comments

Hello!

This is included in the documentation under "Ejecting".

After you do that, just remove all references to expo in your JS code (like you would with any JavaScript package) - there are no references to it in a new CRNA project, so if you didn't use it in your code then you're good to go.

Alternatively, you could create a new project with react-native init and copy and paste your JS files into it. If you have already ejected to ExpoKit, I recommend taking this approach or reverting back in git to your most recent commit pre-ejecting and eject directly to React Native instead.

We would appreciate if you could write us with more details on exactly what issues you had with Expo! You can reach us at [email protected]. Sorry it didn't work out for you!

Best,
Brent

Actually that documentation doesn't say how to eject, it just says how to install the react-native CLI tool. I think it'd be a good idea to explain the actual steps one would need to take to eject after using CRNA.

You're right, that guide just explains what it is. Oops! It's in the main README though! https://github.com/react-community/create-react-native-app#npm-run-eject

If you want to submit a PR to clarify in ejecting doc that could help.

Yup, sounds like a good idea. I'll sort that out now.

Just made #180. Let me know if it needs any changes, happy to help!

It took me so much time to completely eject the expo and make it runnable.
I faced multiple issues, one after other.

  1. You run the below command
    npm run eject
  2. run the command to build for android
    react-native run-android
  3. You will get " A problem occurred configuring project ‘:app’. > SDK location not found " error
    for this Create local.properties in the andoid project folder and give sdk path in that
  4. Then you will face, exception as " com.android.ddmlib.InstallException: Failed to install all "
    for this update gradle version in build.gradle

like this many more issues you may encounter. I have listed all the issues we face in this process and the solution which worked for me.

See the complete guide for ejecting Expo in this article

BTW Still cannot remove expo from react-native-scripts 👎 Thinking of starting farming career.

@amed - have fun

Was this page helpful?
0 / 5 - 0 ratings

Related issues

witbybit picture witbybit  Â·  4Comments

scf4 picture scf4  Â·  5Comments

JackWReid picture JackWReid  Â·  4Comments

Jawadgee picture Jawadgee  Â·  3Comments

iRoachie picture iRoachie  Â·  5Comments