Calling node.to_string does not display the node itself, only its content. Displaying the node would be more useful in my opinion. I was printing an empty element and a text data and was confused why nothing was printed, as both nodes did not have any child to print.
Calling
node.to_string
does not display the node itself, only its content. Displaying the node would be more useful in my opinion. I was printing an empty element and a text data and was confused why nothing was printed, as both nodes did not have any child to print.