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

Re: Shadow DOM: state of the distribution API

From: Ryosuke Niwa <rniwa@apple.com>
Date: Wed, 06 May 2015 15:50:56 -0700
Cc: Jonas Sicking <jonas@sicking.cc>, Anne van Kesteren <annevk@annevk.nl>, WebApps WG <public-webapps@w3.org>
Message-id: <570E3863-C929-4FE4-AC41-9D70D422E13D@apple.com>
To: Elliott Sprehn <esprehn@chromium.org>

> On May 6, 2015, at 2:39 PM, Elliott Sprehn <esprehn@chromium.org> wrote:
> 
> The 3 proposal is what the houdini effort is already researching for custom style/layout/paint. I don't think it's acceptable to make all usage of Shadow DOM break when used with libraries that read layout information today, ie. offsetTop must work. I also don't think it's acceptable to introduce new synchronous hooks and promote n^2 churn in the distribution.

Sorry, I don't follow. If we're making offsetTop to synchronously return the correct value, then authors can easily write code that performs in Ω(n^2) by obtaining the value of offsetTop between adding/removing direct children of a shadow host.  On the other hand, if we're trying to prevent O(n^2) behavior, then we should be adding API to asynchronously retrieve layout information.

- R. Niwa
Received on Wednesday, 6 May 2015 22:51:25 UTC

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