How to make LayeredDigraphLayout into Double-tree layout

LayeredDigraphLayout meet our needs perfectly, however we want to support the expanding functionality that our layout could expand towards left and right at the meantime.

Kind of like the sample of the double-tree layout (https://gojs.net/latest/samples/doubleTree.html), but with LayeredDiagraphLayout on each side(0 angle and 180 angle)

Any tips how could we make it? Thanks!

Try replacing the two TreeLayouts with two instances of LayeredDigraphLayout,

Yeah, I will try that!

Looks like LayeredDigraphLayout don’t have exactly the same parameter as TreeLayout, so when I tried to use replacing them I got lots of errors.

Looks like: arrangement: go.TreeLayout.ArrangementFixedRoots plays a important role in transfer the layout to a double-tree layout in the sample, however we don’t have the similar parameter in LayeredDigraphLayout.

Any other tips? Thanks!

So basically, I want to use two LayeredDigraphLayouts each with opposite directions and they have a same root node.

I found https://gojs.net/latest/samples/customExpandCollapse.html this exmaple might solve my expanding/extracting nodes problem. Let me try that.