W3cubDocs

/Dart 2

append method

  1. @JSName('appendChild')
Node append (Node node)

Adds a node to the end of the child nodes list of this node.

If the node already exists in this document, it will be removed from its current parent node, then added to this node.

This method is more efficient than nodes.add, and is the preferred way of appending a child node.

Implementation

@JSName('appendChild')
/**
 * Adds a node to the end of the child [nodes] list of this node.
 *
 * If the node already exists in this document, it will be removed from its
 * current parent node, then added to this node.
 *
 * This method is more efficient than `nodes.add`, and is the preferred
 * way of appending a child node.
 */
Node append(Node node) native;

© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/2.0.0/dart-html/Node/append.html