differences between create-react-native-app and exp init

ⅰ亾dé卋堺 提交于 2020-06-16 03:04:11

问题


I found that create-react-native-app is based on expo. but when using exp-cli, it is also based on Expo.

what are differences between create-react-native-app and exp init ?


回答1:


Answer to this question is well documented in expo documentation

Expo & "Create React Native App"

Create React Native App lets you build a React Native app without any build configuration. This may sound familiar to you because Expo does this as well -- when you create a project with XDE or exp you don't have to deal with Xcode or Android Studio configuration files, it just works. This guide is intended to outline some of the key differences between Expo and CRNA (create-react-native-app).

CRNA does not require you to have an Expo account

You can run create-react-native-app YourAppName and off you go. So what does not having an account mean, and what would signing up and using XDE/exp get you -- why do we require it with Expo? Having an Expo account allows you to do the following:

  • Publish your project to a permanent URL, eg:https://expo.io/@community/reactconf2017.See Publishing on Expo for more information.
  • Build binaries for app / play store distribution. To do this with CRNA without using Expo, you would need to run eject.



回答2:


Updated answer:

create-react-native-app was replaced by expo-cli.

https://docs.expo.io/workflow/glossary-of-terms/#create-react-native-app




回答3:


there are some advantages and disadvantages for each

react native app advantage:

You can add native modules written in Java/Objective-C

react native app disadvantage:

Needs Android Studio and XCode to run the projects

expo advantages:

Setting up a project is easy and can be done in minutes

Expo can build .apk and .ipa files

do not need simulator or etc for running your app

expo disadvantages:

You can't add native modules.

your finalize app is more bigger than react native app init

i advice to you read this https://docs.expo.io/versions/latest/introduction/why-not-expo



来源:https://stackoverflow.com/questions/51214823/differences-between-create-react-native-app-and-exp-init

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!