1. mustCallSuper
void detach()

Removes this layer from its parent layer's child list

Source

@mustCallSuper
void detach() {
  _parent?._remove(this);
}