You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, if a given tree node has no children (but the nodes array is defined as empty), the expand/collapse icons still render. I believe that if the length of the nodes array is zero, this should be treated the same as not supplying a nodes property.
My current workaround is for my TreeNode typescript class to provide a trimNodes() function:
public trimNodes() {
if (this.nodes.length == 0) {
delete (this as any).nodes;
} else {
for (const node of this.nodes) {
node.trimNodes();
}
}
}
While this works, and is easy enough, it would be nice if bstreeview handled this internally.
The text was updated successfully, but these errors were encountered:
Currently, if a given tree node has no children (but the
nodes
array is defined as empty), the expand/collapse icons still render. I believe that if the length of thenodes
array is zero, this should be treated the same as not supplying anodes
property.My current workaround is for my
TreeNode
typescript class to provide atrimNodes()
function:While this works, and is easy enough, it would be nice if bstreeview handled this internally.
The text was updated successfully, but these errors were encountered: