@graphty/algorithms / index / singleSourceShortestPathBFS
Function: singleSourceShortestPathBFS() ​
singleSourceShortestPathBFS(
graph,source):Map<NodeId,ShortestPathResult>
Defined in: algorithms/traversal/bfs-unified.ts:290
Find shortest paths from source to all reachable nodes
Automatically optimized for large graphs.
Parameters ​
graph ​
The input graph to search
source ​
The source node ID to compute shortest paths from
Returns ​
Map<NodeId, ShortestPathResult>
Map of node IDs to their shortest path results