RE: [css3-regions] elements vs. selectors

> -----Original Message-----
> From: Tab Atkins Jr. [mailto:jackalmage@gmail.com]
> Sent: Wednesday, April 13, 2011 5:36 PM
> 
> > What troubles me in motivation for slots is that the *only* real reason
> for it is that media queries are hard or impossible to use to create or
> remove elements. But maybe if that is important we need to solve that
> problem instead? Actual use cases would help...
> 
> Well, if you're creating an element via CSS, it doesn't exist in the real
> DOM, thus it's basically a pseudo-element, right?  I don't think we need
> to invent a new and probably-complex method of altering the DOM when we
> already have a mechanism for changing the DOM-as-CSS-sees-it via pseudo-
> elements.
> 
> At least, I doubt an actual DOM-altering mechanism would be any simpler
> than the ::slot mechanism.
> 

I wasn't really proposing a particular dom-altering mechanism, I suggested that we look at what people are really have troubles with and consider options. If adding elements from CSS is in fact the way to go (I am not agreeing it is, not yet), why not just put HTML snippets there? innerHTML is the fastest way to insert elements anyway (regardless of DOM exposure), and there is no way to represent HTMl elements that would be more readable than actual HTML...

Received on Thursday, 14 April 2011 00:44:34 UTC