top | item 17349207

(no title)

onedev | 7 years ago

Others have been coming out and talking about similar experiences with React Native. This thread made the rounds on Twitter and Medium fairly recently:

https://twitter.com/sandofsky/status/1002634185566236679

https://twitter.com/VivekxK/status/1002694526467653632

discuss

order

eysquared|7 years ago

The common thread I see is that mixing native and react-native is hard. Doing so while working across organizations that may or may not use react-native is doubly so. Sometimes this boils down to the technology, knowledge, and the engineering systems needed to support both but I've also found native developers tend to strongly dislike react-native and lobby against whenever they can.

For me, I'm using it to successfully build mobile apps for a large tech company with very limited mobile developer resources. We've been able to ship Android and iOS apps in a couple months using 100% react-native. I attribute a lot of this to knowing the limitations of the platform and designing a cross-platform experience from the start rather than trying to get the "best of native" out of abstracted JavaScript.

I'll always argue that native is the way to go for the best user experience but react-native is a great tool to have in the mobile space.

danabramov|7 years ago

>The common thread I see is that mixing native and react-native is hard.

We've experienced some of the difficulties in this area at Facebook as well. If you're curious, making native <-> JS integration more seamless is a big motivation for the ongoing architectural revamp that we've recently posted about: http://facebook.github.io/react-native/blog/2018/06/14/state...

It's a shame we weren't fast enough to help Airbnb in these areas, but the native interop will get better when the revamp is finished.

mephitix|7 years ago

I invested a lot into a full React webapp - it would be great to share some of that code with mobile apps. I have an iOS background but was intending to make a RN app so that I could share the bulk of the React webapp code and get Android support as well.

I have separation of container components and presentational SFCs so I’m thinking I could easily re-implement UI layers in RN if I wanted to without sacrificing the shared code. Do you think this is a reasonable approach? Or should I ditch RN completely and build native...?

It would be nice if there was a way I could pull that shared JS logic (which really doesn’t have much dependencies) into mostly-native apps without having to adopt RN... maybe I could just repurpose the JS bridge and be aware of its limitations (a sync/serialized/batched..)

kgin|7 years ago

That was my take away as well, which makes sense. I think trying to seamlessly merge functionality across any two paradigms is going to be tougher than sticking with just one or the other. But for any company with an existing app, mixing in is the most likely first baby step into react native.

woolvalley|7 years ago

Yup it's the classic double layer issue. I think the only way to do it right is to go full 'game engine' style, like flutter or unity. With these you have a very small GL library surface area and one platform stack to actually understand for most of your engineers. Maybe something like WebAssembly will be similar.

You often don't hear about these kinds of issues out of game engine makers. I could be totally wrong although since I haven't worked on games.

faitswulff|7 years ago

Don't forget Udacity removing it from their codebase: https://twitter.com/n8ebel/status/1006244834351312897

ex3ndr|7 years ago

Udacity is a bit strange example. This means that they have what? triple size of react native in their main app? That's weird because on android react native blows APK to much larger percentage.

nickspag|7 years ago

Coursera also removed it completely.

rimliu|7 years ago

Source?