by dubcanada · 13y ago · 0 comments
<x-slider></x-slider> can be replaced by <input type="range"> <x-layout> can be replaced with CSS <x-datepicker> can be replaced with <input type="date">
etc etc...
I just don't see any reason why we need to create a whole new set of HTML elements that are not part of any HTML spec just so you don't need to add a few more characters. And 90% of these are just polyfills which already exist.
If you want a rapid HTML5 development look up Emmet and add bootstrap or some other giant framework. Don't start making brand new HTML elements that have absolutely no meaning unless there is 150kb's of JS to read them.
Me thinks that is what people don't like.
Under your logic, any compilation of functionality can be reduced to vanilla, long-hand, zero-abstraction, blocks of HTML, CSS, and JS functions --> Ok everyone, dubcanada has figured out that all the packages on NPM, Bower, and Component, and all the frameworks for UI and CSS, etc, along with many of the other APIs in the DOM, are not reeeeally necessary technically speaking - why did we all waste our time on all that?!?...ugg, what a ridiculous argument.
"If you want a rapid HTML5 development look up Emmet and add bootstrap or some other giant framework" - <x-massive-sarcasm> Oh yeah, duh, why didn't I think of that - wait, there are already giant frameworks that try to provide similar functionality, with less ergonomic interfaces, that are more of a management hassle, all for the low low price of 10x the wire size! Gosh, I love things that provide less utility and weight exponentially more, sign me up! </x-massive-sarcasm>
"I just don't see any reason why we need to create a whole new set of HTML elements that are not part of any HTML" - yeah, you're right, because lord knows we have this fantastic solution right now: <div><div><div><span></span><span></span></div></div></div> - who in their right mind would ever see value in lightweight, tightly encapsulated, auto-instantiating, semantically inferred, components like this: <x-switch role="input"></x-switch>, le sigh.
"Me thinks that is what people don't like." - me thinks you're going to be eating those words by the beginning of 2015.
A. I am all for web components, if you read the parent I was replying too. I answered his question.
B. They aren't "technically speaking"... you don't need a calendar. You can create 3 dropdowns with every date. You don't need a slider you can create a dropdown with 1 to 100. I could go on and on. The reason we do this is so it is easier to use. But "technically speaking" it is not a requirement.
Any ways you seem to be a little angry at the moment, I was never attacking the product lol. I actually like the idea, and I'm a contributor/have used extensively to Montage and Broadway. I was just answering the question that the parent asked.
The problem is that you run out of built-in components really quick. Not sure why Mozilla chose to start with existing controls, but the point here is that it's an easy way to introduce new controls.
'look up Emmet and add bootstrap or some other giant framework. Don't start making brand new HTML elements that have absolutely no meaning unless there is 150kb's of JS to read them.'
The problem is that every framework has a different way of writing controls. This is a standardization of the control model with built-in support in the browsers (FF and Chrome at least). Doesn't take 150kb's of JS at all, or even a framework.
<div class="Foo">...</div>
vs <x-foo>...</x-foo>
Semantically, as far as machines are concerned, there is no difference between these two. For humans, however, the latter is way easier to read if there are some lines between the opening and the closing tag.Custom elements also allow you to create your own shadow DOM, you can have your own "native" functions, and there is also some scoping for CSS.
So since their browser happens to be one that doesn't do those things, why don't they fix their browser?
Did you miss the post specifically calling them
> cross-browser polyfill implementations of existing native not-yet-globally-supported elements
?
And thus it is a polyfill indeed, since IE9 does not support HTML5 input types (and more generally HTML5 form extensions).
Luckily, Brick is open source, so you can file an Issue about it, and if you're interested, even submit a pull request yourself.