Thursday, January 17, 2019

What is difference between CRNA and Expo?

create-react-native-app is the quickest way to start a new React Native project. It uses the Expo client and some of the Expo devtools but not all of them. For example, you don't need to create an Expo developer account to use CRNA and we've found it's faster to get started with CRNA than with XDE (the Expo development app).

Since CRNA projects run in the Expo client, you do have access to most of the Expo APIs such as native maps, audio, OpenGL, and more. There are a couple of exceptions like push notifications that only Expo projects can use, but there are many more similarities than differences between CRNA projects and Expo projects.

CRNA was also designed to give you several paths forward as your app grows. The three paths are:

    Use Expo: You actually can open a CRNA project with the Expo XDE app if you want all the features of Expo including push notifications and IPA / APK files for the App Store / Play Store.
    Eject to ExpoKit: ExpoKit is a native library that includes React Native and the Expo APIs. This path creates Xcode and Android Studio projects with ExpoKit so that most Expo APIs keep working if you were using them before. You then build IPA / APK files the way you would as any other native app.
    Eject to bare React Native: This path gives you a plain React Native project with separate Xcode and Android Studio projects. All modules that come with React Native will work but Expo APIs won't work (use ExpoKit above for that) because this is bare React Native.

Note that when you eject, CRNA won't manage upgrades for you so you're responsible for upgrading React Native.


References
https://github.com/react-community/create-react-native-app/issues/153

No comments:

Post a Comment