Facebook's React vs. Web Components (Polymer)

3,210 views
Skip to first unread message

Clayton Watts

unread,
Jan 24, 2014, 3:53:45 PM1/24/14
to polym...@googlegroups.com
Just posted a question on StackOverflow that could use an answer by someone familiar with both Polymer and Facebook's React library:

What are the main benefits of Facebook's React over the upcoming Web Components spec and vice versa (or perhaps a more apples-to-apples comparison would be to Google's Polymer library)?


Clayton

John Barton

unread,
Jan 24, 2014, 4:48:21 PM1/24/14
to Clayton Watts, polym...@googlegroups.com
I think it would be helpful if you suggested reasons to think these two things are alternatives that need to be compared.
jjb


Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CAGw__zGhMT521agzPxDTTVfaiFh%2BMe9CqAhZnZXTcVJYDWPosA%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.

Brian Di Palma

unread,
Jan 25, 2014, 11:52:13 AM1/25/14
to polym...@googlegroups.com, Clayton Watts, johnj...@google.com
It seems to be addressed in the stack overflow post.

For myself personally the platform will win over using libraries like React everyday as long as I can use the platform.
Currently React works with IE8 which is still a hard requirement for many developers, although I would prefer to use the platform.

I haven't looked at the Custom Elements polyfill code too much but I might experiment with it to see if it could be made work in IE8 with some developer assistance.
Instead of relying on DOM events to upgrade elements get the developer to manually request element upgrade.

It's not ideal but IE8 will probably be an unpleasant burden for many developers for a year if not more.

Shane

unread,
Jul 13, 2014, 8:43:44 PM7/13/14
to polym...@googlegroups.com
I had the same question, and got the same dismissive answers. I don't think people engaged in either community are optimistic about the other since one invades part of the others space.

You wrote: 
  • Native browser support (read "guaranteed to be faster")
That's backwards, if you're talking about dom manipulation. The whole reason for a synthesized dom is because native dom is such a bloated pig. That's React's big selling point. That, and less intrusive than Angular.

Again, when I asked your question, all I got were dismissive answers, so apparently no one in that camp was sure. (..."But Brawndo has electrolytes!" :) 

Post more if you find something interesting!

Michael Bleigh

unread,
Jul 13, 2014, 10:28:27 PM7/13/14
to polym...@googlegroups.com
Addy Osmani recently published a post about using them together: http://addyosmani.com/blog/component-interop-with-react-and-custom-elements/

My take on it is this: Web Components plus things like Object.observe and DOM manipulation observers are going to remove much of the existing need for React by making manipulating and observing the DOM much more efficient. That being said, there will still probably be some cases (Divshot, my company, has some in mind) in which a virtual DOM will still be necessary or preferable for various reasons.

I see React as being something like a specialist in a post Web Components world, to be called in to handle jobs that don't suit the normal DOM well. This is just my two cents.
Reply all
Reply to author
Forward
0 new messages