I'm trying to find a service, library, utility, whatever that converts XML to YAML and includes comments. It's easy to find a lot of XML to YAML converters, but I can't find one that includes XML comments in the YAML output. For example, using the XML input below:
<!-- This section has a comment -->
<CommentedElement>
<ChildElement id="1" />
<ChildElement id="2" />
</CommentedElement>
I want the YAML output to be:
# This section has a comment
CommentedElement:
ChildElement:
-
_id: 1
-
_id: 2