Skip to main content

getItem()

returns the object of the selected item

getItem(): any;

Returns:

The object of a selected item.

Example

const shape = diagram.selection.getItem();
// -> {id: "3", text: "Technical Director", title: "Jerry Wagner", …}