Skip to main content
Module

x/drake/lib/graph.ts>Graph

Drake is a make-like task runner for Deno.
Go to Latest
class Graph
import { Graph } from "https://deno.land/x/drake@v1.6.0/lib/graph.ts";

Properties

errors: string[]
nodes: Map<string, string[]>

Methods

private
dfsVisit(
node: string,
discovered: Set<string>,
finished: Set<string>,
)
addNode(node: string, adjacents: string[]): void

Search the graph for cycles. Each cycle contributes an error message to the list of errors. If no cycles are found the errors list will be empty.