Guides

Auto Scrolling

When navigating with keys or clicking a node in the edges of the screen, the tree will automatically try to scroll the selected node into view.
Also, you can call scrollIntoView on any node to make it visible.

Inner Scroll

Auto scrolling is built-in to the tree. Simply wrap the tree with a container that has a height and you're good.
The tree has an inner element called viewport that is scrollable.

External Scroll (Scrolling as part of the body / other container)

Sometimes you don't want to wrap the tree with a scrollable container, and want the scrolling to be part of a different element.
Use the scrollContainer option for this purpose as described in Options

Demo of scrollContainer


Did this page help you?