editNode() {
    // when using the gui, enable edit mode if it wasnt already.
    if (this.editMode !== true) {
      this.enableEditMode();
    }

    // restore the state of any bound functions or events, remove control nodes, restore physics
    this._clean();
    const node = this.selectionHandler.getSelectedNodes()[0];
    if (node !== undefined) {
      this.inMode = "editNode";
      if (typeof this.options.editNode === "function") {
        if (node.isCluster !== true) {
          const data = deepExtend({}, node.options, false);
          data.x = node.x;
          data.y = node.y;

          if (this.options.editNode.length === 2) {
            this.options.editNode(data, (finalizedData) => {
              if (
                finalizedData !== null &&
                finalizedData !== undefined &&
                this.inMode === "editNode"
              ) {
                // if for whatever reason the mode has changes (due to dataset change) disregard the callback) {
                this.body.data.nodes.getDataSet().update(finalizedData);
              }
              this.showManipulatorToolbar();
            });
          } else {
            throw new Error(
              "The function for edit does not support two arguments (data, callback)"
            );
          }
        } else {
          alert(
            this.options.locales[this.options.locale]["editClusterError"] ||
              this.options.locales["en"]["editClusterError"]
          );
        }
      } else {
        throw new Error(
          "No function has been configured to handle the editing of nodes."
        );
      }
    } else {
      this.showManipulatorToolbar();
    }
  }
call the bound function to handle the editing of the node. The node has to be selected.