Re: [webcomponents] Template element parser changes => Proposal for adding DocumentFragment.innerHTML

On Thu, Apr 26, 2012 at 1:33 AM, Anne van Kesteren <annevk@opera.com> wrote:
> On Thu, 26 Apr 2012 10:05:28 +0200, Ryosuke Niwa <rniwa@webkit.org> wrote:
>>
>> Also, I think Anne convinced me that it's better to deduce the insertion
>> mode from the first element than inventing a new insertion mode (I've
>> asked him to post his reasoning).
>
>
> 1) You cannot look at various elements and make a decision. E.g. if your
> first element is <plaintext> there will not be any other elements.
>
> 2) Defining a new top-level insertion mode while retaining compatible
> behavior might be an interesting exercise in parser complexity, but it's not
> clear there is a benefit (use cases?) and feasibility has not been
> demonstrated (consider handling <p><td><p>, <tr><p><td>, ...). The more we
> can define in terms of the existing parser, the better it is for developers.
> The behavior will be more predictable and there will be less quirks to
> learn.
>
> FWIW, https://www.w3.org/Bugs/Public/show_bug.cgi?id=14694 is the bug on the

I've updated this bug with the current proposal.

> DOM Parsing spec, I don't think there's a bug on the HTML spec (other than
> https://www.w3.org/Bugs/Public/show_bug.cgi?id=16635 for SVG/MathML), but I

There aren't any parser changes required. DocumentFragment.innerHTML
can still provide the "fragment case" with a context element and
procede normally. It's not obvious to me what bug to open against
HTML.

Anne, can we move forward with this?

Also, note that a webkit patch which implements "implied context" is
here: https://bugs.webkit.org/show_bug.cgi?id=84646

> might be mistaken.
>
>
> --
> Anne van Kesteren
> http://annevankesteren.nl/

Received on Monday, 30 April 2012 23:57:35 UTC