react native link using expo?

How can I use react-native link or How can I link a third party library manually in IOS and Android using exponent.

I was trying to link react-native-image-crop-picker but unable to use in exponent.

Answers:

Answer

You can't. It states this very clearly in the docs:

But no native modules…

The most limiting thing about Expo is that you can’t add in your own native modules without detaching and using ExpoKit. Continue reading the next question for a full explanation.

If you want to use anything that requires react-native link, then you need to detach your project and then develop it with or without ExpoKit. You will lose certain features and integrations (off the top of my head, I think Push Notifications via Expo is one of them) when doing so, but that is the trade-off Expo provides as an all-in-one package. When detaching, you lose those features.

Answer

The answer by Michael is correct, but what if I say there is a way in which you can add a custom native module in expo. You can do things like react-native link, and won't lose anything provided by expo like push notification, over-the-air (OTA) updates provided by expo.

Go through this detailed blog which shows how exactly you can do that. https://codersera.com/blog/running-expo-react-native-together/

Note: They have created a starter kit as well, so you don't need to go through the pain of doing the entire setup by yourself. But even if you have the ongoing project, moving to the starter kit is more of a copy and paste.

Let me know if you have any questions!

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.