Skip to content

Is there a built-in way to enable hiding or expanding of all the child nodes of a node? #686

Answered by bcakmakoglu
starter-dev asked this question in Q&A
Discussion options

You must be logged in to vote

There's no built-in mechanism to hide all children of a parent node, no.

You can just toggle it yourself with something like this

const parentId = parentNode.id // let's assume you have to parent node available

getNodes.value.filter(n => n.parentNode === parentId).forEach(c => (c.hidden = true))

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@starter-dev
Comment options

@starter-dev
Comment options

Answer selected by starter-dev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants