[svgwg] Clarify that SVG does not need to be valid XML (#960)

real-or-random has just created a new issue for https://github.com/w3c/svgwg:

== Clarify that SVG does not need to be valid XML ==
The conformance section says:
"Additional conformance classes depend on whether the content is also valid and well-formed XML":

https://github.com/w3c/svgwg/blob/51ff4ba22b5d1d90f61fc6e388595d3e87d7839f/master/conform.html#L550-L551

I think it should say:
"Additional conformance classes depend on whether the content is also well-formed XML".

None of the conformance classes require that the document is *valid* XML.  (The only requirement that seems to be "imported" from XML is the validity of the id attribute.) 

Moreover, none of the examples in the entire spec contain a `<!DOCTYPE svg>` declaration which would be required to be valid XML 1.0. (See [XML 1.0 Section 2.8 "Prolog and Document Type Declaration"](https://www.w3.org/TR/xml/#sec-prolog-dtd), which says "The document type declaration MUST appear before the first [element](https://www.w3.org/TR/xml/#dt-element) in the document.")  

In general, I think it will be helpful to explain in more natural language that:
 - SVG does not need to be valid XML. (Since SVG is defined in terms of XML, readers could reasonably expect that valid XML is required)
 - A DOCTYPE declaration is not necessary nor recommended. (This was removed in https://github.com/w3c/svgwg/commit/96e51895fb4438ec3bea0965c90afc668aaed01c for some reason.)  

Please view or discuss this issue at https://github.com/w3c/svgwg/issues/960 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Thursday, 2 January 2025 09:45:41 UTC