Function allIncomingPaths
- allIncomingPaths<V, E>(edges, nodes?): ReadonlyMap<V, readonly Path<V, E>[]>
Type Parameters
V
E extends {
from: V;
to: V;
}
Parameters
edges: readonly E[]
Optional
nodes: readonly V[]
Returns ReadonlyMap<V, readonly Path<V, E>[]>
- allIncomingPaths<V, E>(edges, nodes, fn): ReadonlyMap<V, readonly Path<V, E>[]>
Parameters
edges: readonly E[]
nodes: readonly V[]
Returns ReadonlyMap<V, readonly Path<V, E>[]>
Construct every possible path between every node in your graph, grouped by the node they finish at.
Every node has a zero-length path to itself.
The default edge accessors are the
from
andto
keys. Pass a pair of getters, and your edges can be any other format: