onComponentDirty method Null safety

void onComponentDirty(
  1. Component component
)

Implementation

void onComponentDirty(Component component) {
  if ((dirt & ComponentDirt.components) == 0) {
    context.markNeedsAdvance();
    _dirt |= ComponentDirt.components;
  }

  /// If the order of the component is less than the current dirt depth,
  /// update the dirt depth so that the update loop can break out early and
  /// re-run (something up the tree is dirty).
  if (component.graphOrder < _dirtDepth) {
    _dirtDepth = component.graphOrder;
  }
}