public function before($nodes) { /** @var \DOMNode|Implementation $this */ if ($this->parentNode instanceof \DOMElement && ($nodes = MutationMacro::expand($this->ownerDocument, $nodes))) { $this->parentNode->insertBefore($nodes, $this); } }