W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2012

Re: [webcomponents] HTML Parsing and the <template> element

From: Dimitri Glazkov <dglazkov@chromium.org>
Date: Wed, 8 Feb 2012 20:45:09 -0800
Message-ID: <CADh5Ky1NWoZyUL+OvPmQWoQjooD+Qkr7MzWo98ZTY_xoBOvwbg@mail.gmail.com>
To: Ryosuke Niwa <rniwa@webkit.org>
Cc: Brian Kardell <bkardell@gmail.com>, Erik Arvidsson <arv@chromium.org>, Henri Sivonen <hsivonen@iki.fi>, Ian Hickson <ian@hixie.ch>, Rafael Weinstein <rafaelw@google.com>, Adam Barth <w3c@adambarth.com>, public-webapps <public-webapps@w3.org>
On Wed, Feb 8, 2012 at 8:16 PM, Ryosuke Niwa <rniwa@webkit.org> wrote:
> On Wed, Feb 8, 2012 at 7:31 PM, Brian Kardell <bkardell@gmail.com> wrote:
>> Then why not something like
>> <template id="a">world</template>
>> <template id="b">hello <partial with="a"></template>
> Right. If we were to disallow nested templates, that's the way to go. The
> question is whether we should disallow nested templates or not.

Okay, I am changing my mind. I don't think we should gate this
discussion on whether nested <template> elements should be allowed.
First, it's a very drastic design decision that will do doubt hinder
the developers of templating libraries. Honestly, I wonder if we
should always aim to avoid making these types of decisions at a
platform level. Second, it possibly doesn't even matter.

If and only if we decide that the contents of <template> element MUST
be perceived as a string--not a DOM subtree--will we face the question
of disallowing nested templates. As demonstrated in IDEA 2, we can
still totally still produce usable--nested or not--inert chunks of
DOM, per initial requirements.

So I think we should get back to answering the question: is it crucial
that template contents are parsed as a character stream? From there,
we can walk either toward puzzling over nested templates or just
moving along, nothing to see here.


> - Ryosuke
Received on Thursday, 9 February 2012 04:45:40 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:26:38 UTC