Gojs.net ->samples -> DOMTree only display certain elements / change root

See Gojs.net -> samples -> DOM Tree : Update Graph after new elements are insert - #2 by walter

You’ll note that that sample’s traverseDom function is already filtering out elements from the DOM. You can modify the function to filter out whatever you like.

You can call the updated traverseDom function with whatever root element you like.