Files
DefinitelyTyped/dagre/index.d.ts
Andy 728bd4841d Remove package.json dependencies for @types/d3 when we can use path mapping instead. (#14102)
* And remove d3's `package.json` since it depends on the latest versions of its components.
2017-01-18 14:45:40 -08:00

27 lines
780 B
TypeScript

// Type definitions for dagre 0.7
// Project: https://github.com/cpettitt/dagre
// Definitions by: Qinfeng Chen <https://github.com/qinfchen>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
export as namespace dagre;
export namespace graphlib {
class Graph {
edges(): Edge[];
edge(id: any): any;
nodes(): string[];
node(id: any): any;
setDefaultEdgeLabel(callback: () => void): Graph;
setEdge(sourceId: string, targetId: string, options?: { [key: string]: any }): Graph;
setGraph(options: { [key: string]: any }): Graph;
setNode(id: string, node: { [key: string]: any }): Graph;
}
}
export function layout(graph: graphlib.Graph): void;
interface Edge {
v: string;
w: string;
}