allElements property Null safety

Iterable<Element> allElements

All elements currently in the widget tree (lazy pre-order traversal).

The returned iterable is lazy. It does not walk the entire widget tree immediately, but rather a chunk at a time as the iteration progresses using Iterator.moveNext.


Iterable<Element> get allElements {
  return collectAllElementsFrom(binding.renderViewElement!, skipOffstage: false);