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

Re: Custom Elements: insert/remove callbacks

From: Elliott Sprehn <esprehn@chromium.org>
Date: Thu, 7 May 2015 22:56:05 -0700
Message-ID: <CAO9Q3iJ9j=xCAS0r3=YHY0BtyUVN6HvqegfkUih4KfdorWLMiA@mail.gmail.com>
To: Anne van Kesteren <annevk@annevk.nl>
Cc: Boris Zbarsky <bzbarsky@mit.edu>, WebApps WG <public-webapps@w3.org>
On Thu, May 7, 2015 at 10:44 PM, Anne van Kesteren <annevk@annevk.nl> wrote:

> On Fri, May 8, 2015 at 7:42 AM, Elliott Sprehn <esprehn@chromium.org>
> wrote:
> > That actually seems pretty similar to what we have, ours is in the form
> of:
> >
> > Node#insertedInto(Node insertionPoint)
> > Node#removedFrom(Node insertionPoint)
> >
> > where insertionPoint is the ancestor in the tree where a connection was
> > added or removed which may be arbitrarily far up the ancestor chain. From
> > that you can figure out all the cases Boris is describing.
>
> Cool. So maybe the DOM specification needs to be updated to have that
> model and we should expose that as low-level hook to web developers.
>

We'd consider adding a new MutationObserver type, we'd prefer not to add
any more tree mutation callbacks. Anything you can do with those you can do
with an ancestorChanged record type and takeRecords().

- E
Received on Friday, 8 May 2015 05:57:13 UTC

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