News for hackers. Stuff that matters.
Re:React Native at Airbnb by ex3ndr on Tuesday June 19, 2018 @03:28PM (#17349606)
While i don't have much experience in RN, but have a decade of mobile native development (android + iOS) and two years of React.

The whole 10 years there were people that think that they can just get "web" technology and speedup mobile development.

Almost always this companies had no mobile engineers that know how this stuff works. Developers that know that you just can't listen to scroll and update animations by sending messages to background js thread. This just completely wrong on mobile. Most mobile devs spend months to make it fast and easy to use. There are no way to do this in most cases on RN. AirBNB's app is a perfect example of this. Trying to deliver "better" experience they completely kill scrolling performance. Even top level iPhones feels laggy. But yay! We have animations! AirBNB's app is barely usable on two-year-old androids. This is just simply wrong, this is not how you can achieve good performance and nice animations on such small devices. In most cases this is a kind of art and a lot of testing and tweaking for every device. This can be done by only ONE talented developer per platform per year. Surely AirBNB has resources. Just take specific screen and tweak it to hell. On the other side, react and declarative kind of state is really doesn't work well for non-page oriented apps. Mapping history of navigation via redux store is just an awful and useless idea that helps with nothing. Right now there are still no navigation library.

Every time i tried to start something in React Native i failed since i wasn't able to apply my skills to make it behave fast there are just no easy way to do this.

React Native for sure is a good thing, but it's evolution shaped by web devs that try to reflect their experience from web development, but building a good mobile app is completely different from web one. For example, there are no dom, UI manipulation is not slow, navigation between pages and keeping it's state is not a problem most of the time (there are no real "back" button that you have to handle somehow). UI frameworks are more mature (while have less API than HTML).

Re:React Native at Airbnb by jeanregisser on Tuesday June 19, 2018 @04:34PM (#17350097)
> Right now there are still no navigation library.

React Navigation and React Native Navigation are both viable options with their own pros and cons. Been using them successfully in different projects.

https://reactnavigation.org

https://wix.github.io/react-native-navigation

Re:React Native at Airbnb by filleduchaos on Tuesday June 19, 2018 @05:37PM (#17350465)
I think what they meant is that there is no built-in production-ready navigation library, which is honestly atrocious.
Re:React Native at Airbnb by k__ on Tuesday June 19, 2018 @07:02PM (#17350983)
I never understood the obsession with native navigation libaries.

I built a bunch of apps with JS navs and nobody ever complained...

Re:React Native at Airbnb by mwcampbell on Tuesday June 19, 2018 @11:03PM (#17352237)
Did you test your app with VoiceOver, the iOS screen reader for blind people? The difference between non-native and native navigation is particularly noticeable in that case, unless perhaps you fire a UIAccessibilityScreenChangedNotification after navigating to a new screen.

That's just the scenario I'm aware of. I haven't done any real projects with React Native, so there may be other pitfalls.

Re:React Native at Airbnb by LeoNatan25 on Wednesday June 20, 2018 @03:08AM (#17353228)
Of course not. They are a lazy developer that care little about the user experience.
Re:React Native at Airbnb by mwcampbell on Sunday June 24, 2018 @03:10PM (#17387882)
As passionate as I am about accessibility, I try not to use an accusing tone. There's no way we can know the state of mind, priorities, and constraints of the developer in question. Even large companies don't have unlimited resources. So we can't fault developers for looking for ways to do more with less. We just need to do what we can to make sure developers are informed about the pitfalls, and plead with them to consider important user experience factors like accessibility.
Re:React Native at Airbnb by filleduchaos on Tuesday June 19, 2018 @11:17PM (#17352296)
"Built-in" and "native" don't mean the same thing last time I checked.
Re:React Native at Airbnb by morenoh149 on Tuesday June 19, 2018 @11:56PM (#17352471)
I think you mean 'built-in' into react native? Facebook routinely lets the community settle on the correct api aside from a limited core.

E.g. react router on web has gone through many versions and there are several community libraries for doing web navigation and how you want to track that application state.

Re:React Native at Airbnb by filleduchaos on Wednesday June 20, 2018 @02:32PM (#17358257)
And as a result there's a ton of churn, waiting for third parties to update their libraries (sometimes forever) and beginners having to make choices on how to do the most basic things without the experience or knowledge to help them make good decisions.
Re:React Native at Airbnb by morenoh149 on Wednesday June 27, 2018 @10:56PM (#17413721)
It's just beyond the needs of fb and what they cared to provide for. No one is paying for the extra dev work, so until some other entity pays or volunteers that will be the situation. Incidentally, Expo did extend RN to cover many of the missing APIs. It's just the reality we live in.
Re:React Native at Airbnb by com2kid on Tuesday June 19, 2018 @11:16PM (#17352289)
> that they can just get "web" technology and speedup mobile development.

RN isn't really web technology. It is a JS engine along side a cross platform API translates API calls to the appropriate underlying native platform code. UI components rendered by RN do not use web tech at all.

It is no different than Xamarine in that regard, and has many of the same drawbacks.

> AirBNB's app is barely usable on two-year-old androids.

I never had problems with it on my Nexus 5x, and everything was a lag fest on that phone. (Lag in daily use got so bad after moving to Android 8 that I had to get a new phone just for my sanity.)

For a large # of apps, RN works just fine. Its real promise is not "web technology", so far as it is 99% code sharing across platforms.

The other players in this market don't have the same community drive that RN does, so people gravitate towards RN.