News for hackers. Stuff that matters.
Re:Why did Airbnb dump React Native? (2021) by gigel82 on Tuesday August 16, 2022 @08:37PM (#32490902)
> Mobile engineers didn’t want to write RN code and web engineers didn’t want to build on mobile

That's interesting. In our experience, we're having a difficult time hiring folks that want to write native (including UI) in antiquated languages and frameworks - but it's much easier to hire JavaScript folks that just hack at RN.

Of course, someone still needs to stand up the actual platform, as well as write shared (and sometimes platform specific) pieces of functionality mostly in C++ so for now I guess us oldtimers still have some job security :)

Re:Why did Airbnb dump React Native? (2021) by wingerlang on Tuesday August 16, 2022 @11:56PM (#32492148)
This is an iOS only perspective, but it sounds like you are not actually looking too hard for iOS developers?.

No iOS developer considers Swift antiquated (because it isn't). I'd argue no one even considers UIKit antiquated (middle aged, maybe). Maybe with the exception of brand new iOS developers who has jumped on the SwiftUI-only bandwagon. SwiftUI itself is so new that it barely is production ready.

Sounds to me like you are actually looking for web developers who doesn't want to start learning native, but are OK to do the work in JS.

Re:Why did Airbnb dump React Native? (2021) by gigel82 on Wednesday August 17, 2022 @12:52AM (#32492502)
Sorry, just realized most folks associate React Native with mobile. We target that too, but we're mostly targeting desktop platforms (via React Native Windows and React Native macOS) - and in our case antiquated really means antiquated (think old-school custom XML-based UI framework).
Re:Why did Airbnb dump React Native? (2021) by tomduncalf on Wednesday August 17, 2022 @05:09AM (#32493978)
How are you finding using RN on desktop? When I last looked into it (more than a year ago) RN Mac felt a bit lacking. There was no way to do drawing of custom paths (eg SVG) for example.

Ended up using react-native-web in an Electron container to make a desktop version of an RN app, which worked surprisingly well.

Re:Why did Airbnb dump React Native? (2021) by wingerlang on Wednesday August 17, 2022 @02:12AM (#32492885)
I see, in that case I understand it more.
Re:Why did Airbnb dump React Native? (2021) by dimmke on Tuesday August 16, 2022 @09:05PM (#32491052)
Yeah they think they know React Native until they have to debug something that is outside the happy path that is provided to them.

These people probably have never worked on a production RN app or done upgrades and maintenance for one.

Re:Why did Airbnb dump React Native? (2021) by dimmke on Tuesday August 16, 2022 @11:47PM (#32492097)
I want to clarify since this is getting upvoted, I still think RN is a better option than maintaining two separate apps in the vast majority of cases.

It just suffers because everybody "knows React" so how hard could it really be and people get hired into roles working on RN with very little understanding of how it's different from a web based React project.

Re:Why did Airbnb dump React Native? (2021) by metadat on Wednesday August 17, 2022 @12:54AM (#32492509)
The promise of achievable unification with high-quality polished UX ends up being empty. React is complex.
Re:Why did Airbnb dump React Native? (2021) by FlyingSnake on Wednesday August 17, 2022 @02:13AM (#32492897)
> folks that want to write native (including UI) in antiquated languages and frameworks

I’m which land is Kotlin and Swift antiquated? Both a modern and cutting edge technologies with stellar toolchain and 1st class IDE and platform support.

Re:Why did Airbnb dump React Native? (2021) by programmarchy on Tuesday August 16, 2022 @09:31PM (#32491220)
I wouldn’t call Swift (or Kotlin) antiquated. I’m sure it’s easier to hire JavaScript developers to hack on React Native because the talent pool is larger, but I’d wager your app quality will suffer. Depending on the app, sometimes a first class user experience just isn’t a high priority, in which case native-focused developers aren’t going to be attracted to working on it.
Re:Why did Airbnb dump React Native? (2021) by dimmke on Tuesday August 16, 2022 @11:30PM (#32492010)
>I’d wager your app quality will suffer.

I really dislike this argument, and it comes up every time React Native is discussed. I think it's a holdover from Ionic style mobile applications that simply emulated native UI in a webview. It was awful - especially when the native UI changed and the Ionic apps didn't. It's likely you use RN apps every day and don't even notice because they're indistinguishable from native apps.

React Native is designed to compile down to native code and it uses native UI frameworks. The documentation on how it does this is very thorough. The problem is not React Native in my opinion. It's the native UI frameworks for iOS and Android. These frameworks have a lot of issues and taming them often requires developers with a lot of time and experience in that specific domain. Which is stupid and wasteful.

Here's a story from yesterday of how Apple's SwiftUI (their much vaunted successor to UIKit, a very flawed framework itself) is struggling to construct basic settings views in the new version of MacOS: https://daringfireball.net/linked/2022/08/15/ventura-system-...

Not to mention the criticism of Swift as a language and how it has evolved, including the original creator leaving. And how complicated doing a fucking substring is: https://stackoverflow.com/questions/39677330/how-does-string...

In my opinion, Flexbox is a perfect way of laying out elements on a 2D screen. It's way less confusing than the complex constraints system that UIKit used. React Native's implementation of it works well. Kotlin and Swift as DSLs do not need to exist. They are solutions in search of a problem. Designed by big tech to moat their platforms.

Unless you're building an app that has a very non standard UI or a game, it doesn't make sense not to use React Native in my opinion.

Re:Why did Airbnb dump React Native? (2021) by programmarchy on Wednesday August 17, 2022 @01:03AM (#32492549)
There’s always going to be a performance penalty for React Native applications because of the JavaScript bridge, and on iOS you’re giving up ARC memory management for your app logic. For basic stuff you can write it off, but doing anything cutting edge like AR, custom graphics drawing, custom text layout and input, etc. is off the table. Even picking up a new iOS feature (e.g. focus filters) is a pain because you need to maintain a layer of bridge code, or wait for a third party module to catch up.

One somewhat direct comparison is Discord (RN) vs Telegram (Swift) on iOS. Discord has put a massive engineering effort into their app but switching channels still often feels glitchy and sluggish whereas Telegram’s layouts snap into place instantly. Telegram feels more solid, and it also properly wires up all the little iOS features like haptic feedback, pull to refresh, etc. whereas Discord mutes all of that and feels less lively.

Regarding constraint-based layouts, they can actually be much simpler in many cases because they help you avoid deep layers of nesting. They also ensure consistency (leading and trailing margins, safe areas, etc.) Again, trade-offs that deal in performance and uniformity with the platform.

For CRUD type apps, it probably doesn’t matter. But like I said those probably aren’t the types of apps native developers would be most interested in building.

Re:Why did Airbnb dump React Native? (2021) by kuschku on Wednesday August 17, 2022 @12:45AM (#32492466)
Look at the new Discord app. It's significantly slower than previously ever since the switch to react native, and has significantly more hangups.

React native works maybe fine if your target device is the highest end iPhone, but if your users are on Android One devices, it's not going to work nearly as well.

That's aside from the layouting being obviously off compared to the native layout engines.

Re:Why did Airbnb dump React Native? (2021) by wiseowise on Wednesday August 17, 2022 @02:43AM (#32493055)
It works just fine if you actually profile and see what are the bottlenecks.
Re:Why did Airbnb dump React Native? (2021) by kuschku on Wednesday August 17, 2022 @02:59AM (#32493150)
I'd love to, sadly it doesn't appear to be open source ;)

I can say from comparing pre-RN and post-RN apps side-by-side on a Nokia 6.2 it's definitely much slower (scrolling immediately drops frames, opening/closing the keyboard and other reflows e.g. multiwindow cause the app to hang for seconds).

Re:Why did Airbnb dump React Native? (2021) by tled on Wednesday August 17, 2022 @09:05AM (#32495798)
> Kotlin and Swift as DSLs do not need to exist. They are solutions in search of a problem Don't know what your problem is, Kotlin and Swift are both superior to JS
Re:Why did Airbnb dump React Native? (2021) by dwaite on Wednesday August 17, 2022 @01:17AM (#32492620)
> Here's a story from yesterday of how Apple's SwiftUI (their much vaunted successor to UIKit, a very flawed framework itself) is struggling to construct basic settings views in the new version of MacOS:

A journalist who is not an iOS developer saying something 'feels wrong' doesn't mean much in terms of quantitative evaluation of SwiftUI.

Others have already commented elsewhere on the source material (a list of UX nits) was based on a one month old beta release, and many had already been fixed at the time the list was published - something the author of that list neglected to point out at first.

> Not to mention the criticism of Swift as a language and how it has evolved, including the original creator leaving.

People leave. Rob Pike has mostly stopped working on Go. Graydon Hoare left Mozilla - and worked on Swift for a time.

> And how complicated doing a fucking substring is:

I don't understand your reference. String manipulation on Swift has gotten markedly easier since Swift 3 (when that page was created), but it is still meant to be correct/safe unicode grapheme manipulations at its core. Swift's character type is essentially a variable length, special-case of string.

Most Swift string criticisms come down to - if you want to treat text as offsets into a (mutable) binary buffer, work with binary buffers and not unicode strings.

> In my opinion, Flexbox is a perfect way of laying out elements on a 2D screen. It's way less confusing than the complex constraints system that UIKit used. React Native's implementation of it works well. Kotlin and Swift as DSLs do not need to exist. They are solutions in search of a problem. Designed by big tech to moat their platforms.

AppKit and UIKit's original constraint system was simple, even simplistic.

The constraint system that was built on top was sophisticated, but is generally too fiddly. You pretty much need training in the interface builder to understand how to get constraints to apply and stick.

This was quite simply because it was a bolt-on constraint solver over a layout engine with multiple decades of legacy. No layout options went away when constraints were added - instead, the system had to adapt to having (workarounds) for all the different approaches to operate concurrently.

I don't quite understand what technical complaints if any you have of Kotlin DSL or of SwiftUI's layout systems, so I can't speak to that.

> Unless you're building an app that has a very non standard UI or a game, it doesn't make sense not to use React Native in my opinion.

I'm curious what makes something a 'standard UI' when doing native cross-platform development.

Re:Why did Airbnb dump React Native? (2021) by dimmke on Wednesday August 17, 2022 @10:10AM (#32496626)
>A journalist who is not an iOS developer saying something 'feels wrong' doesn't mean much in terms of quantitative evaluation of SwiftUI.

Calling John Gruber a "journalist" is reductive. He is the inventor of markdown and has a history as a software engineer himself. He is also one of the most notable people who tracks things that many would consider obscure like Apple UI frameworks.

>I don't understand your reference https://news.ycombinator.com/item?id=32325511

The standard library and API surface of Swift has changed dramatically every release. They don't have a real problem to solve, and they know they have a guaranteed userbase of their language, so it's gotten progressively weirder and shittier over the years.

>I'm curious what makes something a 'standard UI' when doing native cross-platform development.

Not that curious, because it's pretty easy to look up what React Native offers: https://reactnative.dev/docs/components-and-apis. Things like text inputs, buttons but also bigger conceptual stuff like list views and app navigation: https://reactnative.dev/docs/navigation. Those UI elements render differently in different mobile operating systems and React Native handles both gracefully.

Re:Why did Airbnb dump React Native? (2021) by dwaite on Thursday August 18, 2022 @11:26PM (#32517333)
I like Gruber, he has a CS degree and had a brief career as a web developer (which certainly helps him write about technology as well as keep his site operational), but he has been a full-time columnist for his own tech blog for 16 years. As far as I know, he does not have experience writing client side code, either using AppKit/UIKit or using a tool like React Native.

He has plenty of people in his network who are professional developers with SwiftUI experience. However, he was talking about his gut feel from a core system service having so many UI nits from Apple, likely associating that with issues he has heard of from developers who have tried to adopt SwiftUI in their existing and/or new projects.

So thats the basis of my opinion - a quote or two from those full-time developers would added greatly to the article, significantly more his personal reaction.

As a developer with some client-side experience, I'd say the nits speak far more to Apple's MacOS development process these days than to the quality of SwiftUI. A decision was made to add it to the 13 beta and commit to shipping it, rather than hold it back for macOS 14.

Re:Why did Airbnb dump React Native? (2021) by hitekker on Tuesday August 16, 2022 @09:42PM (#32491299)
> antiquated languages and frameworks

Yikes, I hope you're not calling Kotlin or Swift antiquated. That's utterly false.

Re:Why did Airbnb dump React Native? (2021) by tuxpenguine on Tuesday August 16, 2022 @11:24PM (#32491969)
Some people think only javascript/typescript is modern. The javascript cult hopes everything to be written in js.
Re:Why did Airbnb dump React Native? (2021) by trevyn on Tuesday August 16, 2022 @09:48PM (#32491339)
Swift = effectively proprietary = antiquated.
Re:Why did Airbnb dump React Native? (2021) by junon on Tuesday August 16, 2022 @10:16PM (#32491534)
That's some interesting logic.
Re:Why did Airbnb dump React Native? (2021) by shams93 on Wednesday August 17, 2022 @01:08AM (#32492574)
Yeah the frameworks are painful to work with and require extremely powerful (and expensive) systems to develop with while js can be learned on any old low end chromebook.