r/reactnative • React Native Team • Mar 11 '19

AMA We’re the React Native team. AUA!

Hi everyone, we are the React Native team at Facebook!

There is a lot of stuff happening in the world of React Native right now. 0.59 will be cut soon and is a highly anticipated release. Among other things it will include React Hooks and an updated JSC on Android.

We’ve also been improving how we listen and communicate with all of you. We recently put up a new blog post on the progress we’ve made with the open source community. I highly recommend giving it a read. One of my favorite points from that post is that in the last 3 months we’ve gone from 280 open pull requests to ~65. We get so many pull requests every day, this required handling ~600 pull requests, about 2/3 of which were merged!

There are a ton of improvements coming to React Native from all of you and we are still hard at work on Fabric and the rearchitecture of the core to enable even more impressive things to be built with React Native.

It is a pleasure to be here and we are really excited to hear and answer your questions. Our team will be answering questions from 2PM-3PM PST (5PM-6PM EST, 22:00 - 23:00 GMT). Feel free to start asking and upvoting questions!

----------------

Update: Thank you for taking the time to hang out with us. This has been great and we’ve had a blast answering your questions. Feel free to follow us on twitter:

212 Upvotes

224 comments sorted by

View all comments

45

u/[deleted] Mar 11 '19

[removed] — view removed comment

14

u/jameside Expo Team Mar 11 '19

In short, for the docs, a lot of collaboration and sustained energy has gone into helping people get started on a variety of computers and phones, like using Windows or Linux to get running on iOS.

I'd say the Expo and React (Native) teams work mostly independently in a friendly way. At the end of the day, React Native is still very small compared to traditional Xcode and Android development and growing this future of development is by far one of the most important things to do.

A corollary is that we work together to help grow this ecosystem. From both personal and company perspectives I believe this is very much a positive-sum space and working with friends at Facebook contributes to growing the pie.

11

u/EngVagabond React Native Team Mar 11 '19

I don't think this part of the documentation has changed recently. I would like to provide some context from my understanding of how we got here though.

From when React Native was open sourced, our team's main priority has been on the needs of Facebook and driving the fundamentals and architecture of React Native forward. Expo however was able to originally focus on the new user experience of React Native. This has been amazing for the ecosystem and we are immensely grateful they are part of the community.

Looking forward, we've been working on making the default getting started experience better by improving the default template and the upgrading / linking experience. Expo and other companies like Infinite Red have been talking with us about other improvements we can make to the default CLI that would enable more seamless integrations with other platforms like Expo or others.

18

u/JofArnold Mar 11 '19

I'd also like to know why. I love Expo and the team are amazing but I'm super suspicious of a startup gaining mindshare in an important ecosystem. For instance, Apollo have become so entrenched they are basically "GraphQL" to many people; this has resulted in some less-than-ideal behaviour on their part.

6

u/minhtrungaa Mar 11 '19

I worked over 10 projects without expo , heard here and there it just a bunch of block wall. What do you mean "heavily depend"?

7

u/thedevlinb Expo Mar 11 '19 edited Mar 11 '19

On multiple occasions the React Native website's instructions for getting started with a new RN project w/o expo have been just plain wrong.

As in, if you follow them, you'll get Gradle build errors. Especially if an existing Android Studio install exists. (I imagine they work if you freshly format a machine and follow them?)

The label on the instructions for not using Expo is "Building Projects with Native Code". There are other reasons to not use Expo, but the listed reason is native code support. That label only makes sense if a new developer already knows what Expo is, that the default instructions will set them up with Expo, and what the limitations of Expo are. At that point, the developer is beyond a basic "getting started guide".

Basically, Facebook is directing new React Native developers towards Expo, what looks like an independent third party project thats has no obvious source of revenue or funding, yet one that maintains a fully featured backend infrastructure including build servers and a mobile messaging platform.

Now to be fair to Facebook, the instructions for React Native development w/o expo are rather... long and detailed, at least for Android. And Android development can be fragile in regards to Gradle updates breaking the living daylights out of everything.

11

u/EngVagabond React Native Team Mar 11 '19

We definitely don't want our instructions to be wrong. Unfortunately, since our team doesn't frequently create new projects internally and instead work on long existing apps, we rarely go through the getting started experience. For better or worse, we rely on the community to help us maintain this documentation and it is important to us to make sure we have a good getting started guide for using React Native, with or without Expo.

6

u/c4d4 Mar 11 '19

RN definitely doesn't depend on it, although it certainly tries to promote it. I tried to go the expo route when I first started using RN a few months ago but immediately ran into issues:

- I needed the community version of the WebView because postMessage was not working correctly in the core one. In fact the docs for the core WebView even say that you should just use the community one. Well turns out this requires linking, eg, no Expo.

- If you need to store anything secure, such as a password, API token, etc, you'll probably need react-native-sensitive-info... requires linking.

- If you decide to use the react-native-navigation by Wix (also listed in RN's docs alongside the non-native React Navigation), you'll need to link.

- If you decide to use Sqlite, you'll need to link.

- It looks like there's even a better-maintained version of AsyncStorage in the community org that would require linking.

- If you decide to use TouchID / FaceID, you'll need to link.

- If you decide to use DeviceInfo to get OS, device version, etc, you'll need to link.

Anyways, my point is that I'm amazed when people are able to pull of full apps using Expo given how many things have required me to link them.

7

u/brentvatne Expo Team Mar 11 '19

hey c4d4! perhaps you missed it in documentation, a lot of what you mentioned is actually just included in the sdk by default.

- secure keychain / keystore https://docs.expo.io/versions/v32.0.0/sdk/securestore/

- face / touch id https://docs.expo.io/versions/v32.0.0/sdk/local-authentication/

- sqlite https://docs.expo.io/versions/v32.0.0/sdk/sqlite/

- deviceinfo stuff https://docs.expo.io/versions/v32.0.0/sdk/constants/

have a look at the rest of the API Reference section to see what else is available - push notifications, video, audio, background location, background fetch, etc.

re: community webview and asyncstorage, those were just pulled out of react-native since our last sdk release and we'll include them in our next release. we release every couple of months in order to get the latest stable version of react-native, update a bunch of our libraries and add new features, etc.

also, almost all of the apis from expo are available on bare react-native apps too: https://blog.expo.io/you-can-now-use-expo-apis-in-any-react-native-app-7c3a93041331

1

u/c4d4 Mar 11 '19

This is great to know! Thanks.

I had to give up on Expo pretty much immediately upon starting RN because of the Webview issue and my decision to use React Native Navigation so I guess I had missed all of this. It's great that you're including all of this out of the box!

Unfortunately I'm also using threads and background fetch which I think would also limit my ability to use it though :(

2

u/brentvatne Expo Team Mar 11 '19

can you elaborate on what you mean by using threads?

2

u/c4d4 Mar 11 '19

1

u/brentvatne Expo Team Mar 11 '19

oh neat! thanks. edit: out of curiosity, what do you use it for?

2

u/c4d4 Mar 11 '19

I'm doing some encryption, compression, and syncing in the background that was causing a bit of UI lag. Putting it into a "thread" smoothed it out! :)

1

u/brentvatne Expo Team Mar 12 '19

neat, sounds like a perfect use case for something like this

1

u/[deleted] Mar 11 '19

Running stuff in the background

Running cpu intensive work without freezin the UI

Also, expo doesn't allow for background work

1

u/brentvatne Expo Team Mar 12 '19

indeed - i was curious about the concrete use case that c4d4 asked. not sure what you're referring to re: background work, as a generalized term it's not so useful, it's best to talk about specific use cases - expo managed workflow currently supports background location and background fetch.

1

u/[deleted] Mar 12 '19

I think the last part of my comment is wrong. I had read that it didn't support background work as in code running with the app in foreground. Also knowing iOS doesn't allow that easily.

10

u/pvinis Mar 11 '19 edited Mar 11 '19

I still think without expo is easier to work with RN. That said, I am not the target audience. The team has done some cool stuff, that's true.

6

u/filth9 Mar 11 '19

This is what I wanted to know. Expo resolves some problem especially for beginner. I’m so heavily using expo because it’s easy to deploy to iTunes connect and google play console.

I wonder if RN team would provide useful deploy tool for both platform android and iOS like expo.