Re: Shadow DOM: Hat and Cat -- if that's your real name.

On Feb 4, 2014, at 5:33 PM, Edward O'Connor <eoconnor@apple.com> wrote:
> 
> Tab wrote:
> 
>> We've just figured out that, in the general case, we need full
>> shadow-piercing. We'd like to explore more restricted methods of
>> piercing that people can opt into in the future.
> 
> I think this is backwards. We should start with an opt-in mechanism and
> allow authors to opt-in their entire shadow tree if they really want
> that.
> 

I would add that if Google does believe fast adoption will make some changes effectively impossible then there is no reason to expect ^^/::shadow's default level of access to the shadow tree to be any easier to change later on (defaulting to a loose model and changing to a strict one later is rarely a good time). Fast adoption makes 'fixing it later' way more expensive across the board, not just for syntax.

Choosing the right default here seems a rather fundamental issue that deserves wide consensus before shipping anywhere. I'd love to hear more from Google on how they intend to justify the current default to would-be component developers given that, as Roc pointed out, CSS access to custom components' internals is the default today and the whole point of shadow DOM was to fix that. Is the assumption that 'shadow nodes will never match existing selectors, only new ones with the ^^ combinator' represents 'enough' encapsulation 'for now'? 

Received on Wednesday, 5 February 2014 02:35:57 UTC