I am actually working on windows and I have to parse xml from a file.
The issue is when i parse the root element, and get the children via the child
method, I am getting empty children.
XML.load("my_path\\sof.xml").child
res0: Seq[scala.xml.Node] = List(
, <b/>,
)
This is my xml file
sof.xml
<a>
<b></b>
</a>
But when I remove every \n and \r of the file like this :
sof.xml
<a><b></b></a>
I got the following result which is expected
res0: Seq[scala.xml.Node] = List(<b/>)
My question is, is there an option to read it correctly from the intended form?