renderAndReplace method

void renderAndReplace(
  1. VNode? parent,
  2. Node node
)

Renders a newly created (this) virtual node and replaces the content of node with the new content.

Implementation

void renderAndReplace(VNode? parent, Node node) {
  renderNew(parent);
  node.replaceWith(this.node!);
}