[webcomponents] Use x:: instead of x-?

<x-bikeshed>


Would it be possible to use "::" instead of the "x-" prefix in custom  
element names? i.e. allow any name as long as it contains "::" somewhere:

<foo::bar>

or

<button is="foo::bar">


1. The "::" is used for pseudo-elements in CSS, and for namespaces in C++,  
both of which seem somewhat related.

2. "x-" is (subjectively) ugly, and has been used for experimental  
extensions elsewhere. IMHO it's a bit of an eye-sore in the otherwise  
elegant design.

3. document.createElement('::foo') works. <foo::> parses (unfortunately  
<::foo> doesn't).


Use of "::" would naturally allow some namespacing of reusable components:

<jqueryui::widget>
</jqueryui::widget>

(not True Namespaces in the XML sense, but IMHO that's also a good thing).  
If I understand correctly, serialisation of "::" in XML isn't a problem,  
as XML documents could use the is="" attribute instead.

-- 
regards, Kornel Lesiński

Received on Wednesday, 9 May 2012 20:26:00 UTC