DOM Level 1 Compatibility Checker
Thursday October 19th, 2000
#3 Whitespace should stay
by MPocock <email@example.com>
Monday October 23rd, 2000 4:48 AM
You are replying to this message
The whitespace issue depends upon whether the documents is validated or not. In the case of no validation, all white-space should be kept. This is because there is no way to know if an element contains text as a child.
Once a document is validated against a DTD or a schema, then we can decide which whitespace is there as content, and which is prety-printing stuff as the document structure tells us what children each element should have. At this point, the DOM should not contain any extraneous text nodes.
Does this make sence?