innerText property

  1. @override
String get innerText
inherited

Return the concatenated text of this node and all its descendants.

Implementation

@override
String get innerText => XmlDescendantsIterable(this)
    .where((node) => node is XmlText || node is XmlCDATA)
    .map((node) => node.text)
    .join();
  1. @override
set innerText (String value)
inherited

Replaces the children of this node with text contents.

Implementation

@override
set innerText(String value) {
  children.clear();
  if (value.isNotEmpty) {
    children.add(XmlTextSyntheticImpl(value));
  }
}