contains method

bool contains(
  1. Component c
)

Whether the children list contains the given component.

This method uses reference equality.

Implementation

bool contains(Component c) => children.contains(c);