appendChild method

  1. @override
  2. @mustCallSuper
Node appendChild(
  1. Node child
)
inherited

Implementation

@override
@mustCallSuper
Node appendChild(Node child) {
  super.appendChild(child);

  _debugCheckNestedInline(child);
  if (isRendererAttached) {
    // Only append child renderer when which is not attached.
    if (!child.isRendererAttached) {
      if (scrollingContentLayoutBox != null) {
        child.attachTo(this, after: scrollingContentLayoutBox!.lastChild);
      } else if (!_isIntrinsicBox) {
        child.attachTo(this, after: _renderLayoutBox!.lastChild);
      }
    }
  }

  return child;
}