Skip to content

Thin python wrapper around dagre-d3

License

Notifications You must be signed in to change notification settings

liwancheng91/dagre-py

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dagre-py

https://img.shields.io/travis/com/Vernacular-ai/dagre-py/master.svg?style=flat-square https://img.shields.io/pypi/v/dagre-py.svg?style=flat-square

Thin python wrapper around dagre-d3 for building quick dags with tooltips and a few other niceties. It’s not really generically usable right now, but you can try something like:

from dagre_py.core import plot

plot({
    "nodes": [
        {"label": "A"},
        {"label": "B", "description": "This is an output node"}
    ],
    "edges": [{"source": "A", "target": "B", "label": "edge1"}]
    "edges": [{"source": "A", "target": "B", "label": "edge2"}]
})

With the following effect:

./screens/multi-edges.png

For more description of the data that goes in, check the docstring of dagre_py.core.plot function.

About

Thin python wrapper around dagre-d3

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 39.0%
  • Python 33.6%
  • CSS 15.7%
  • HTML 11.7%