layout

layout.cube

cube(nodeIds?: string[], options?: CubeLayoutOptions): Promise<void>

Arrange nodes at the vertices of a cube.

Recorded in history as "SetPositions" or "DragPositions". Emits "layout:start" and "layout:end".

nodeIdsstring[]Subset of nodes to lay out; defaults to all nodes.
optionsCubeLayoutOptionsEdge length and other cube parameters.

Returns: Promise<void>

Example

await api.layout.cube();
await api.camera.flyToAll();