unloadSubtree function

void unloadSubtree(
  1. Node node
)

Detaches a loaded lazy subtree node's content; it can be loaded again with loadSubtree. No-op if node is not a lazy placeholder.

Implementation

void unloadSubtree(Node node) {
  if (lazyInstanceOf(node) == null) {
    debugPrint(
      'fscene: unloadSubtree on a node that is not a lazy placeholder',
    );
    return;
  }
  node.removeAll();
}