Skip to content

[dagre] Dagre graphlib types are wrong #47439

@Timmmm

Description

@Timmmm

Dagre uses Graphlib, and has a copy of Graphlib's type definitions. If you compare Graphlib's type definitions with Dagre's copy, you can see that they are very different.

As far as I can tell the Dagre copy is completely wrong (or out of date). For example:

        node(id: string | Label): Node<T>;

You can't look up a node by its label (which is an arbitrary Record<string, unknown>). Graphlib's types have this correct:

    node(name: string): any;

(well, ignoring the fact that it returns any rather than Record<string, unknown>)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions