* Rafael Weinstein wrote: >I think looking at this as whether we are "breaking the correspondance >between source and DOM" may not be helpful -- because it's likely to >be a matter of opinion. I'd like to suggest that we look at more >precise issues. > >There are several axes of "presence" for elements WRT to a Document: > >-serialization: do the elements appear in the serialization of the >Document, as delivered to the client and if the client re-serializes >via innerHTML, etc... >-DOM traversal: do the elements appear via traversing the document's >childNodes hierarchy >-querySelector*, get*by*, etc: are the element's returned via various >document-level query mechanisms >-CSS: are the element's considered for matching any present or future >document-level selectors
And one might take the position that all of these should be defined in terms of what you call "DOM traversal", making them all the same, with- in the confines of a DOM View, a concept that has fallen out of favour. >The goal of the <template> element is this: the page author would like >a declarative mechanism to author DOM fragments which are not in use >as of page construction, but are readily available to be used when >needed. Further, the author would like to be able to declare the >fragments inline, at the location in the document where they should be >placed, if & when they are needed. > >Thus, template require that its contents be "present" for only >serialization, and not for DOM traversal, querySelector*/etc..., or >CSS. I do not see the "thus" here. -- Björn Höhrmann · mailto:bjo...@hoehrmann.de · http://bjoern.hoehrmann.de Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de 25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/