Live data from Hacker News

Introducing React Native [video]

youtube.com

81–90 of 193 posts

Re: Introducing React Native [video]

#81

I wish they'd go into more detail on why they can't make an app like paper in the browser environment. They mentioned something about Web Workers being crippled and later on explained how their framework puts JavaScript in it's own thread by default. I'm also wondering why in their experience no one ever comes close to native widgets when imitating them in a Web apps.

with gpu-accelerated css transitions, requestAnimationFrame, virtual dom and web workers, the experience can be damn close. he makes it seem like "no comparison", this is provably false at least for the apps he demoed. for games, native is still necessary. what react offers beyond performance though, is definitely awesome. imo, the talk comes off a bit like a sales pitch at a pep rally.

You're right that it's possible to get really, really close, but the effort required is very large and best avoided if possible. Not to mention, there will always be subtle differences between your UX and native, and it sucks to be in a position where you have to defend that difference to, say, your CEO who's asking why "it just feels different." Or worse, he can put his finger on exactly why it feels different and it's some tiny glitch that's out of your control but ruins the "polish" of the app in his opinion. It puts you in the position of either busting your ass to achieve the impossible or defending mediocrity.

Re: Introducing React Native [video]

#83
I'm Jordan and I'm on the React (and React Native) team. There's been some great questions and insight on this thread. React Native offers a ton of benefits around productivity (and ability to use React of course), but since there are many questions about performance, I thought I'd share some of my own personal perspective on the matter.

React Native is very different than other approaches because:

1. We're not promising to give you One Weird Trick that allows you to change nothing about your development philosophy/practices and yet automatically create excellent mobile experiences. If you're developing for mobile, and you want an excellent user experience, you must care about performance and you must care about programming nuanced interactions. Behind any great mobile experience, is someone who cared. Don't believe anyone that tells you differently. However, I feel that the amount of work that React Native asks of developers in order to achieve it, is much less than any other alternative that I've seen.

2. React Native doesn't use the DOM at all. React naturally tames many of the performance issues that typically arise from unpredictable programming practices in the browser, but that can only get you so far. React Native takes it to the next level, beyond what can be done in the browser. React Native shows that ReactJS has always been more about "zero DOM" than "virtual DOM" (contrary to popular belief).

4. React Native is different because we want to keep some of the best parts about web development. Just because we want the performance and resource control of native views, that doesn't mean we should abandon the great things about the web. With React Native, you can use CSS FlexBox to lay out your native views, and many other familiar style attributes - but without the catastrophic CSS style reflows. The event system also works exactly as it does in your React apps today because it runs the same library code. By building in terms of the subset of web styles/layout that we know we can make fast native implementations for, it allows developers to build great apps today without setting back progress of the web in the future. I feel this is strictly better than encouraging developers to abandon anything remotely resembling web technology and instead learn a completely different toolchain (or two or three).

3. React Native is different because it makes high quality apps written in JS possible. With browsers, you will likely run up against a fundamental limitation and there's nothing you can do about it. Either you don't have access to a platform component (certain scroll view with physics/Maps), or the interaction that you're implementing keeps getting interrupted by image decoding and there's nothing you can do about it.

With React Native, you can do something about it. You can build ReactJS apps using native platform views that could never be implemented in JS (like Maps), and you can also build using higher performing granular building blocks (multi-threaded decoded ) ( blocks that don't use the DOM at all). The result is that this unlocks an unprecedented level of quality that feels great and matches the platform characteristics.

Re: Introducing React Native [video]

#84
I wonder why it is such a big of a deal of not having DOM API:s on the WebWorker thread? I think the discussion from Browser vendors is that there is no use case or benefit of having them there.

And not having the "native feel" or performance. I think browser vendors are on the verge on closing this gap totally. If not browser vendors, hardware will do it.

Re: Introducing React Native [video]

#85
post #79

I'm part of the group that thought "what the hell?" when I first saw the React syntax - but seeing this has completely changed my mind and I'm really looking forward to picking up React as soon as possible. If this delivers on its promises (no reason to assume it won't, seeing as it's already being used in large apps) then it's going to change the mobile development landscape. It sounded like they may even be hinting…

> when I first saw the React syntax

Do you mean JSX? Because "the React syntax" is just plain JS unless you're using JSX, is it not? IIRC even vdom nodes can be created by hand with literal objects.

Re: Introducing React Native [video]

#86

I'm Jordan and I'm on the React (and React Native) team. There's been some great questions and insight on this thread. React Native offers a ton of benefits around productivity (and ability to use React of course), but since there are many questions about performance, I thought I'd share some of my own personal perspective on the matter. React Native is very different than other approaches because: 1. We're not promi…

Do you guys have a set of cross platform components like , , that will work across Android , iOS and Web ?

The native components might behave slightly different on each platform so I was wondering if you guys have subclassed the native components to behave similarly on all platforms.

Re: Introducing React Native [video]

#87

I wish they'd go into more detail on why they can't make an app like paper in the browser environment. They mentioned something about Web Workers being crippled and later on explained how their framework puts JavaScript in it's own thread by default. I'm also wondering why in their experience no one ever comes close to native widgets when imitating them in a Web apps.

with gpu-accelerated css transitions, requestAnimationFrame, virtual dom and web workers, the experience can be damn close. he makes it seem like "no comparison", this is provably false at least for the apps he demoed. for games, native is still necessary. what react offers beyond performance though, is definitely awesome. imo, the talk comes off a bit like a sales pitch at a pep rally.

Do you have any examples of apps that come damn close ?

Re: Introducing React Native [video]

#88
So I have a simple question; how is this better than Swift or Objective C? It seems like Facebook has done everything in its power to avoid writing Objective C. I am also interested to know if this is what powers the current 1.7 star rated Facebook app. I am just having a hard time understanding how Facebook has earned much credibility with their mobile efforts. Also, how is this different or better than Ruby Motion? I just don't get it. We've had a lot of these fake native solutions but how does it work with existing Cocoa libraries, etc. I think the bigger question is why? Is Facebook allergic to actually writing Java ObC or Swift? Before the downvotes, consider the history and track record and quality of Facebook on mobile. I honestly don't know the answers to the above questions (they aren't completely rhetorical.)

Re: Introducing React Native [video]

#89

I'm Jordan and I'm on the React (and React Native) team. There's been some great questions and insight on this thread. React Native offers a ton of benefits around productivity (and ability to use React of course), but since there are many questions about performance, I thought I'd share some of my own personal perspective on the matter. React Native is very different than other approaches because: 1. We're not promi…

Hi Jordan, I'm interested on which CSS rules causes reflows?

Re: Introducing React Native [video]

#90
post #54

Earlier quoted context omitted.

It's not about DOM. UIKit is pretty sofisticated to build layer to translate JS to native code. It needs years of work and constant update.

::cough:: https://twitter.com/andy_matuschak/status/560511204867575808

He is just talking about layer model. Being iOS engineer for 4 years and Web developer for 5 years, These frameworks only works for certain use cases and at the end you wish that you did the right thing from beginning.
Post reply on HN