diff --git a/lib/node.js b/lib/node.js index 88acc2c..9657872 100644 --- a/lib/node.js +++ b/lib/node.js @@ -257,6 +257,17 @@ class Node { return this } + /** + * Add a node as this nodes next sibling + * @param {nextNode} node the node to be added + * @returns {this} + */ + append(nextNode) { + domUtils.append(this._element, nextNode.get()) + + return this + } + /** * Replaces a child element with a new child * @param {Node} newChild the new Child @@ -289,7 +300,7 @@ class Node { */ appendChildAfter(newChild, existingChild) { domUtils.append(existingChild.get(), newChild.get()) - + return this }