W3C home > Mailing lists > Public > public-webapps@w3.org > April to June 2012

Re: [webcomponents] Custom Elements Spec

From: Dimitri Glazkov <dglazkov@chromium.org>
Date: Fri, 4 May 2012 10:08:30 -0700
Message-ID: <CADh5Ky1d6T11LoDFBqbXDHfnb7TQihM_cSQt_FXqedXceai89A@mail.gmail.com>
To: Ian Hickson <ian@hixie.ch>
Cc: public-webapps <public-webapps@w3.org>
On Thu, May 3, 2012 at 9:19 PM, Ian Hickson <ian@hixie.ch> wrote:
> On Tue, 1 May 2012, Dimitri Glazkov wrote:
>> Custom tags vs. "is" attribute
>> - "is" attribute is awkward, overly verbose
>> - custom tags introduce local semantics
>> - perhaps start with something as simple as reserving "x-" prefix on
>> HTML tags for local semantics.
> Whether it's
>   <x-colour-picker fallback="select">
> ...or:
>   <select is="colour-picker">
> ...you have the same level of awkwardness. The advantage of the second
> one, aside from being less ugly and generally terser, is that it actually
> has workable fallback in legacy UAs -- the first one would only work in
> UAs that supported components or at a minimum knew enough about components
> to know how the fallback mechanism worked. (Also, the first one runs the
> risk that authors would start forgetting to give a fallback, with its
> resulting implications on accessibility, search engines, etc.)

I completely agree, given these two choices. However, it's possible we
have more choices that these two -- they just haven't been discovered.

I am happy to see that there is a momentum in JS frameworks toward
using DOM tree as a composition medium (Microsoft's WinJS, AngularJS,
QuickUI, and others), and they will undoubtedly have to solve this
problem. I'll be watching for cowpaths.


> --
> Ian Hickson               U+1047E                )\._.,--....,'``.    fL
> http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
> Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Friday, 4 May 2012 17:09:00 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 18:13:34 UTC