Live data from Hacker News

Introducing React Native [video]

youtube.com

21–30 of 193 posts

Re: Introducing React Native [video]

#21
post #2

Here's the moment in the video where it's announced: https://www.youtube.com/watch?v=KVZ-P-ZI6W4#t=1341

And just as a heads-up to those who haven't watched, implementation details and code samples are coming tomorrow.

But basically the tl;dw seems to be that you can write JavaScript React code that runs efficiently on mobile and renders native primitive components instead of dom primitives ( instead of ).

It also introduces the idea of "Learn once, write everywhere" instead of "Write once, run everywhere", which I think is a great idea.

Re: Introducing React Native [video]

#23
post #4

Earlier quoted context omitted.

No, React Native translates a declarative API into imperative calls. Just like React does in the browser (after going through the Virtual DOM as, essentially, an optimisation).

Yes, just like the DPS interpreter translates (high-level) DPS into (low-level) pixels. Looks pretty similar to me. (but then I am not overly familiar with DPS or ReactJS) EDIT: To clarify, I am sure that the current UIKit also tries to do optimize rendering. They probably do some kind of internal batching, etc. But they have no (public) data format like DPS or a virtual DOM that is generated, optimized and rendered.…

It's not similar. Postscript (display or "regular") is imperative. It's an instruction stream.

React belongs one level "up", abstracting away the translation from a declarative representation of the view to a stream of calls on some lower level mechanism to reproduce that representation in the most efficient way possible.

The basic idea of React is that instead of having your application spitting out an instruction here and an instruction there, which may result in lots of reflows and redrawing, if individual state changes are expensive it can be more efficient to re-create a full representation of the desired state and have an engine compare that desired state to the actual state and figuring out the best possible set of steps to get from the actual to desired state.

E.g. the engine may be able to figure out that a subtree changes so much it's going to be best to just replace it wholesale instead of manipulating node by node.

The "output" from a React style engine can be a series of DOM manipulations, or it could be DPS instructions, or any number of other things - the idea is very general.

Re: Introducing React Native [video]

#24
I think this can be really amazing as is react js now.

--

I had to build a simple at first but very complex under the hood. I wrote that app in a weekend with react and was a ton fun and most important worked well since day one.

I have been out from the web development since like 1.5 year, but yeah IMO react is the best thing happened to javascript since ... ever.

Thanks again guys!

Re: Introducing React Native [video]

#27
post #17

Sorry, dumb question, don't feel like watching the video: What platforms are targetted? Out of, say, iOS, Android, Linux/X11 desktop, Windows desktop, WinRT, OSX?

This is Eric, from the React Native team. We're starting with iOS and Android, which will keep us busy for the foreseeable future. That said, we will open source soon, and we'd be happy to accept help targeting other platforms!

This is awesome.

I can't wait for the API docs and sources to be released.

Tweets and videos are lousy at conveying information : )

Re: Introducing React Native [video]

#28
post #5

If I'm one of Reacts competitors I'm ecstatic that they're abandoning the web. It reminds me of when Angular wastes energy on angular.dart because of a Google mandate. Didn't help them much.

> If I'm one of Reacts competitors I'm ecstatic that they're abandoning the web.

Wait, can you quote where they said that. Maybe a particular time in the video...

Re: Introducing React Native [video]

#29
post #17

Sorry, dumb question, don't feel like watching the video: What platforms are targetted? Out of, say, iOS, Android, Linux/X11 desktop, Windows desktop, WinRT, OSX?

This is Eric, from the React Native team. We're starting with iOS and Android, which will keep us busy for the foreseeable future. That said, we will open source soon, and we'd be happy to accept help targeting other platforms!

Very interesting. Microsoft allows you to build fully native (not webview wrappers) apps using WinJS, and they have shown that React (along with Angular) can be used to build those apps [1]. I wonder if Microsoft will put resources into bridging the gap between React Native and Windows 10.

As a long time web oriented .NET developer wanting to pick up mobile who has been wondering whether to go Cordova or dive in fully native (ObjC/Java/Xaml) this is going to make the choice very difficult.

[1] https://github.com/winjs/winjs/wiki/Using-WinJS-with-React

Re: Introducing React Native [video]

#30
post #17

Earlier quoted context omitted.

This is Eric, from the React Native team. We're starting with iOS and Android, which will keep us busy for the foreseeable future. That said, we will open source soon, and we'd be happy to accept help targeting other platforms!

Very interesting. Microsoft allows you to build fully native (not webview wrappers) apps using WinJS, and they have shown that React (along with Angular) can be used to build those apps [1]. I wonder if Microsoft will put resources into bridging the gap between React Native and Windows 10. As a long time web oriented .NET developer wanting to pick up mobile who has been wondering whether to go Cordova or dive in full…

Honest question: Would you even need something like react on windows given that wpf/winrt already support dependency properties and data binding?
Post reply on HN