Live data from Hacker News

Custom Elements v1: Reusable Web Components

developers.google.com

11–20 of 41 posts

Re: Custom Elements v1: Reusable Web Components

#11
Customs Elements is what would make me quite happy with UI design on the browser side.

Now just have to wait a few years to be able to use it, or hope the polyfills actually cover all the browsers versions we might need to target.

Re: Custom Elements v1: Reusable Web Components

#15
Components with extensibility through inheritance written in a prototype-based language. Having worked with around a dozen component-based systems over the years I'm not particularly enthusiastic.

I think it would be much better for the web if browsers had a sane API for extending behaviors of any tag via attributes. This would make things easily composable and eliminate most problems of traditional component-based systems.

    
It would be even better if people working on these specs spent some time reading research papers on how a sane component-based system could work. For example: http://alumni.media.mit.edu/~mt/thesis/mt-thesis-Contents.ht... A lot of interesting ideas regarding extensible behaviors and ease of understanding.

Edit: And yes, I'm aware of is="" functionality. It's not exactly what I'm talking about. In fact, if the specs were designed the way I mentioned, there would be no need for making anything special for built-in elements as opposed to the new ones.

Re: Custom Elements v1: Reusable Web Components

#16
This is the kicker for me:

> At time of writing, no browser has implemented customized built-in elements. Chrome plans to implement them (status) but other browsers have expressed distaste for implementing the is="" syntax.

I would love to just be able to "fix" the normalization around several built-in elements.

Re: Custom Elements v1: Reusable Web Components

#17

could it replace React ?

We've been using Web Components + Virtual DOM to build our web apps for the last year at Mixpanel: https://github.com/mixpanel/panel. The biggest issues have been dealing with polyfill issues (especially Shadow DOM leakage) and versioning elements (given the global namespace issue of "registerElement")

Re: Custom Elements v1: Reusable Web Components

#20
post #15

Components with extensibility through inheritance written in a prototype-based language. Having worked with around a dozen component-based systems over the years I'm not particularly enthusiastic. I think it would be much better for the web if browsers had a sane API for extending behaviors of any tag via attributes. This would make things easily composable and eliminate most problems of traditional component-based s…

> It would be even better if people working on these specs spent some time reading research papers on how a sane component-based system could work.

I don't know the people working on these specs, but presuming that they aren't aware of research in the area, and moreover of what has worked in practice and what hasn't, is audacious.

Post reply on HN