innerText property
String
innerText
Return the concatenated text value its descendants.
Implementation
String get innerText => descendants
.where((node) => node is XmlText || node is XmlCDATA)
.map((node) => node.value)
.join();
Replaces the children of this node with text contents.
Implementation
set innerText(String value) {
XmlNodeTypeException.checkHasChildren(this);
children.clear();
if (value.isNotEmpty) {
children.add(XmlText(value));
}
}