Hello Tymek,
This exception comes from the “item” that you pass to the ensureVisible() function.
Try passing the HTMLElement of the item you want to ensure visible.
For example:
let item = document.getElementById("10");
this.tree.ensureVisible(item);
or
let selectedItem = this.tree.getSelectedItem();
this.tree.ensureVisible(selectedItem.element);
It depends on how you get the item.
If this does not work, please, send a larger example of your code.
Best Regards,
Martin
jQWidgets Team
http://www.jqwidgets.com/