toddmotto / ama

Ask me anything!
20 stars 3 forks source link

What do you think of Web Components? #5

Closed benoror closed 8 years ago

benoror commented 8 years ago

Particularly, do you see it as the future for a more modular & simplified (web-)development?

toddmotto commented 8 years ago

I wouldn't say it was simplified at all!

I've had this conversation with many people too, even with a Polymer core team members at Google IO a few years back. I went home and tried Polymer on an existing OS project to get a real grip of the concepts behind Web Components and make an educated argument for discussions for/against it and it's concepts. I also wrote an introductory article on it.

In brief; I love Web Components, however their adoption is somewhat hindered by the broadness of the spec and time taken to implement it. By this time, we've already built far superior JavaScript tools and compilers/wrappers that do a far better job. Saying that, adopting Web Components features (such as Angular making use of ShadowDOM) is a fantastic step forward for web tech!

benoror commented 8 years ago

Great :+1: Thanks!

benoror commented 8 years ago

BTW, what do you think of the limitation to pass strings-only to components' attributes:

When Sebastian Markbage (one of React’s creators) was asked about Web Components, he answered:

... How do you pass data when everything is a string?...

Source: www.2ality.com/2015/08/web-component-status.html

More specifically, do you see web components complementing JS frameworks, or even replacing them completely in the mid-term?

toddmotto commented 8 years ago

Wow, comments are extremely interesting in that thread.

I said above "we've already built far superior JavaScript tools and compilers/wrappers that do a far better job", my short and best answer is that I don't think anyone within the next 5 years will actually be doing this in production:

<link rel="import" href="google-map.html">
<google-map></google-map>

... Unless you work at Google haha :P

benoror commented 8 years ago

:laughing: for the sake of context:

https://twitter.com/toddmotto/status/677218985495166976

@toddmotto interesting stuff, thanks!