I'm studying YAML as a replacement for XML, but I'm experiencing difficulties when dealing with elements containing free-flowing text with embedded elements. For instance, the following XML document:
<text>
This is an example text, spanning multiple lines, and it has embedded elements
like <a p="value">this</a> and <b>this</b>. There is also a list:
<quote>
<text>The text of the quote, spanning multiple lines, and it has
embedded elements like <c p="value">this</c> and <b>this</b></text>
<author>The Author of this quote</author>
</quote>
Text continues here.
</text>
I don't know how to convert the embedded elements in YAML. My understanding is that the above XML document segment translates to something like this (except for the embedded elements):
text: >
This is an example text, spanning multiple lines, and it has embedded
elements like <a p="value">this</a> and <b>this</b>. There is also a
list:
quote:
text: >
The text of the quote, spanning multiple lines,
and it has embedded elements like <c p="value">this</c>
and <b>this</b>
author: The Author of this quote
Text continues here.
Also, is indentation not needed in some places?