addChildToElement method

  1. @override
bool addChildToElement(
  1. Node? parent,
  2. Node? child
)
override

Implementation

@override
bool addChildToElement(Node? parent, Node? child) {
  if (parent == null || child == null) return false;

  if (parent is Element) {
    if (!_isChildOfElementImpl(parent, child)) {
      parent.append(child);
      return true;
    }
  }

  return false;
}