dispose method

  1. @override
void dispose()
override

Release any resources held by this node.

Implementation

@override
void dispose() {
  parentNode?.removeChild(this);
  assert(!isRendererAttached, 'Should unmount $this before calling dispose.');
  super.dispose();
}