React.js, what's this all about?

It seems like many on Hacker News are wetting their pants over React.js yet I can’t seem to put my finger on what makes it “great” or even if it is “great.”

How does React fit into the Rails world? Is this something that would supplant Ember et al.?

There’s also the “native app” development aspect of React where, according to our mobile-savvy friends at Facebook is a way to build “native” apps using React.js. This sounds a bit like their experiment with HTML5 wrapping for their early mobile apps. But, I don’t know enough to know if this is actually a real thing or not. How does “native” React fit into Obj. C and Swift?

I’m honestly confused about where React is supposed to fit into our universe.

React is a framework for javascript views built by facebook. It is not a full framework like Angular or Ember. It is only the view layer. It’s extremely fast and performant because it is able to use a virtual DOM diff to render changes. It has some benefits like being able to be dropped into legacy apps and with out the overhead of trying to use angular or ember inside of those legacy apps.

I think its great in certain use cases, and It can be used in rails app just like any other javascript library. So feel free to dig into it and check it out.

1 Like

The biggest selling point is the virtual DOM. It’s something people didn’t think could be performant and they made it work. So that’s why it has a lot of hype around it. Plus it does have facebook backing it which in general helps, however ember is following suite and implementing a DOM diff in their new view layer HTMLbars, you can see them talking about it here [WIP] Reactive rerendering by wycats · Pull Request #282 · tildeio/htmlbars · GitHub.