Live data from Hacker News

First Impressions Using React Native

jlongster.com

101–110 of 195 posts

Re: First Impressions Using React Native

#101
post #81
post #55

Earlier quoted context omitted.

Agree that singletons for Flux are bad, but they're totally not necessary (e.g. https://github.com/acdlite/flummox ). And if you don't like Flux, don't use it. I don't see how that's can be a demerit against React, since they're completely separate things.

React doesn't have a good pattern for passing information up the tree other than Flux. Prior to Flux they told everyone to pass functions through props which is fine up until a certain point but it doesn't scale to large apps. Flux does solve it, and is a generally good idea, but the singleton pattern breaks when applied to the server.

Ah, I see. I don't really agree, because I think the enforced unidirectional data flow is one of the best parts of React, but that's certainly a valid point of view.

I just want to emphasize again that Flux is entirely possible without singletons, and works just as well on the server if you create new instances for every request. Flummox does it, Fluxible does it (at least for stores). It's just a shame Facebook pushed singletons and then everyone followed their lead.

Re: First Impressions Using React Native

#102
post #99

So if this is native widgets etc., the main point is being able to write this in JavaScript, right? Anything in it for those who don't consider this inherently beneficial? Souns a lot like GWT, s/Enterprise "architects"/Web "ninja"/ to me.

It's not about "Write once, run everywhere" but rather about "Learn once, write everywhere". React-Native encourages better design patterns for UI, especially on iOS.

This blog post summed it up perfectly for me: https://joshaber.github.io/2015/01/30/why-react-native-matte...

Re: First Impressions Using React Native

#104

Declarative UI is boss. I know Andy (former UIKit team) was quoted in the intro thread but I'll do it again: >I say with confidence as a former UIKit author: React's model for the UI layer is vastly better than UIKit's. React Native is a huge deal. https://twitter.com/andy_matuschak/status/560511204867575808 If you're averse to React because of JSX, “mixing templates and views” and similar superficial “best practices…

MS have been doing declarative UIs for literally 8 years (XAML).

Re: First Impressions Using React Native

#106
post #91

Earlier quoted context omitted.

Very cool! I'll keep an eye on your work!

Me too. I'd love to chat more about this with both of you, this seems like a direction definitely worth exploring. Maybe we could set up a github project for it? Or talk in an issue on your existing repo, nwienert?

Sweet. I'll watch out for wherever you guys end up.

Might be worth reading one of the react native devs about why animations might still be hard: http://jlongster.com/First-Impressions-using-React-Native#co...

This idea is also why I hooked up the css-layout project (https://github.com/facebook/css-layout) to a live demo to play around with: http://layout.jlongster.com/

Re: First Impressions Using React Native

#107

OK this DOM stuff is great but what about the other HTML5 interfaces, like sending requests to the server, localStorage, etc. ?

There is an API-compatible XMLHTTPRequest so all libs that have those deps (Backbone) work. There is also localStorage (not in this release though), but it's not 100% compatible because it has an async API.

Is the localStorage going to be something similar to IndexedDB (or localForage perhaps?)

Re: First Impressions Using React Native

#109

    "React Native actually performs the layout on
     a separate thread, so the main thread is as free
     as it can possibly be to focus on smooth animations 
     (it also provides flexbox for layout,
     which something that no other framework provides)" 
Interestingly - though perhaps increasingly less relevant - this is how BlackBerry 10 platform native QML-based applications work as well.

Re: First Impressions Using React Native

#110
post #75

Earlier quoted context omitted.

> What the web has going for it (and what native will never catch up to) is having solved the distribution problem. apt-get, yum, app stores, click once, web start, ...

Right: fragmented, environment dependent, user learning curve, etc. Web: URL + links

Web: Network always on required (offline apps is a joke), code behind a pay wall, data behind a pay wall, forced upgrades, removal of features without respect for the users, no guarantee of availability
Post reply on HN