dependo / 0.1.3 last updated 3 months ago created on Mar 5th 2013
Install
npm install --save dependo
Clone
git clone git@github.com:auchenberg/dependo.git
dependencies
show all 15
| main |
|
commander | 1.0.0 | MIT |
|
|
underscore | 1.4.4 | MIT | |
|
|
madge | 0.3.1 | MIT |
maintainers
versions
| 0.1.3 | 3 months ago | auchenberg |
| 0.1.1 | a year ago | auchenberg |
readme
dependo
Visualize your CommonJS or AMD module dependencies in a force directed graph report - powered by D3.js.
Introduction
Let me introduce dependo - A small visualization tool that draws an force directed graph of JavaScript dependencies that has been annotated with either CommonJS, or AMD. Behind the scene I’m using a wonderful library named node-madge, to extract the dependencies and combined with the power of D3.js I draw a beautiful zoomable directed graph.
You can read the full introduction to the project in my blog post.
Features
- Draw a graph of nodes, where each module is represented as a node.
- Google Maps's like zooming, dragging and panning.
- Connect nodes with it's dependencies via lines.
- Hovering a node will highlight it's direct dependencies.
- It's possible to drag a node to a specific position, to re-layout the graph.
Report example
The best way to show something is by example, so here I generated a graph of the official RequireJS multipage example:

See the example here: http://auchenberg.github.com/dependo/example
Installation
To install as a library:
To install the command-line tool:
API
CLI
Generate HTML report of all module dependencies (AMD), and save it to /example/report.html
Grunt
I also wrote a grunt-task that can be found in this seperate repository: https://github.com/auchenberg/grunt-dependo
Roadmap
dependo is still very much in progress, so here is the todo-list:
- Proper label positioning: Avoid label collisions and make the graph more readable.
- Testing! Unit tests of D3 render logic, and the grunt-task itself
Thanks to
This project would'nt have been possible without the great work on node-madge by Patrik Henningson, or wonderful D3.js library.