code: function(html) {
        var range     = rangy.createRange(this.doc),
            node      = range.createContextualFragment(html),
            lastChild = node.lastChild;
        this.insertNode(node);
        if (lastChild) {
          this.setAfter(lastChild);
        }
      }
docs: Insert html at the caret position and move the cursor after the inserted html
  
  @param {String} html HTML string to insert
  @example
  selection.insertHTML("<p>foobar</p>");