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

Re: [webcomponents]: Making <link rel="components"> produce DocumentFragments

From: Dominic Cooney <dominicc@google.com>
Date: Wed, 13 Mar 2013 14:20:31 +0900
Message-ID: <CAHnmYQ8m-Ce_FwSrGFZYqbEKSCJFWkuBFbAAMVkt+wxtniskOA@mail.gmail.com>
To: Dimitri Glazkov <dglazkov@google.com>
Cc: public-webapps <public-webapps@w3.org>, Elliott Sprehn <esprehn@gmail.com>
On Tue, Mar 12, 2013 at 8:13 AM, Dimitri Glazkov <dglazkov@google.com>wrote:

> Hi folks!
> Just had a quick discussion with Elliott and he suggested that instead of
> building full-blown Documents, the <link rel="components"> just make
> DocumentFragments, just like <template> does.

I am confused by what you are proposing here.

Templates "produce" document fragments in the sense that the
HTMLTemplateElement's content attribute is a DocumentFragment.

On the other hand, templates use full-blown documents in the sense that
"the template contents owner is a document which does not have a browsing
context." <

> Looking at
> http://www.whatwg.org/specs/web-apps/current-work/multipage/dom.html#the-document-object and
> the bunch of APIs that will never be useful on a document without a
> browsing context, I think it's a pretty good idea. It should make also
> components more lightweight.

It you are proposing to make the Component interface's content attribute a
DocumentFragment, I think that is OK. It does not make the components any
lighter, because component.content.ownerDocument will inevitably point to
that other document.

Could you provide a more specific proposal? I don't understand what you're
proposing here.

> The only problem is that now I have to figure out how to specify this
> without just flat-out stealing, err... I mean reusing, large swaths of
> HTML5 spec. But I'll take this one for the team.
> :DG<

Email SLA <http://goto.google.com/dc-email-sla> •
Received on Wednesday, 13 March 2013 05:21:02 UTC

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