ancestorElements property
Return a lazy Iterable of the ancestor XmlElement
nodes of this
node (parent, grandparent, ...) in reverse document order.
Implementation
@override
Iterable<XmlElement> get ancestorElements => ancestors.whereType<XmlElement>();