I'd like to use a VerticalScrollbar composable alongside the tree, both to give an indication of where it currently is, but also to allow scrolling through the tree much faster when there are millions of nodes in the tree.
VerticalScrollbar needs to be given the same LazyListState you give to the LazyColumn - but the current API gives me no way to pass this in.
As an aside, I did try adding 1,000,000 items to a tree, and it became ultra slow to expand the tree. It's quite possible I'm using the API incorrectly though, I just created a Branch and then called Leaf 1,000,000 times, similar to what I was doing for my existing code.
My own tree prototype from tonight's effort can add 1,000,000 items with no noticeable delay, but has multiple deficiencies I'd have to fix to make it usable in production, so I'm exploring all the other options out there before I resort to writing a tree component myself.
I'd like to use a
VerticalScrollbarcomposable alongside the tree, both to give an indication of where it currently is, but also to allow scrolling through the tree much faster when there are millions of nodes in the tree.VerticalScrollbarneeds to be given the sameLazyListStateyou give to theLazyColumn- but the current API gives me no way to pass this in.As an aside, I did try adding 1,000,000 items to a tree, and it became ultra slow to expand the tree. It's quite possible I'm using the API incorrectly though, I just created a Branch and then called Leaf 1,000,000 times, similar to what I was doing for my existing code.
My own tree prototype from tonight's effort can add 1,000,000 items with no noticeable delay, but has multiple deficiencies I'd have to fix to make it usable in production, so I'm exploring all the other options out there before I resort to writing a tree component myself.