Re: [w3c/webcomponents] The is="" attribute is confusing? Maybe we should encourage only ES6 class-based extension. (#509)

I dont know what happened to me but I had the patience today to read this entire thread. 

**Having is="" is better because:**

1) It provides progressive enhancement and compatibility (Apple and Firefox dont intend to support them now and maybe in future)

2) It allows the search engines to understand the type of element (It will become difficult for the search engines to understand extended custom elements. Mutation Observers is not an option as well)

3) It allows the javascript disabled browsers to use the webcomponents (since it can use the native functionality that time)

4) Less code and can use the existing native implementation of the platform for the elements

5) Along with all this, it also gives good readability doing <button is="fancy-element"> tells that I am defining a custom element named FancyElement extending button but doing <fancy-element></fancy-element> does not tell me that it is of button type unless I see the element definition.

Don't worry about the future input/other type of elements getting sub classed since the pros keeping sub-classes is more than the cons.

PS: These are personal views only. May differ.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/webcomponents/issues/509#issuecomment-261737160

Received on Saturday, 19 November 2016 20:24:20 UTC