dagre-graph

Build hierarchical graph diagrams with DagreGraph in Vue dashboards.

427|25|Updated Mar 16, 2025
One-click install
npx skills add https://github.com/dennisadriaans/vue-chrts --skill dagre-graph
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dagre-graph
Source: https://github.com/dennisadriaans/vue-chrts/tree/main/.claude/skills/dagre-graph
Command: npx skills add https://github.com/dennisadriaans/vue-chrts --skill dagre-graph

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

DagreGraph components simplify building directed graphs with automatic hierarchical layouts, enabling developers to render organizational charts, dependency trees, flowcharts, and decision trees without manual positioning.

Core Features & Use Cases

  • Hierarchical layout: automatic ranking and edge routing for TB, LR, and other directions.
  • Custom visuals: control node color, size, shape, and label accessors.
  • Interactivity: respond to node and link events and apply dagreSettings for layout tweaks.
  • Use Case: visualize a company org chart with levels and reporting lines using a single data structure.

Quick Start

Import DagreGraph from vue-chrts and render with a data object: import { DagreGraph } from 'vue-chrts'; const graphData = { nodes: [ { id: 'ceo', label: 'CEO', level: 0 }, { id: 'mgr', label: 'Manager', level: 1 } ], links: [ { source: 'ceo', target: 'mgr' } ] }; // In your component template <DagreGraph :data="graphData" :dagreSettings="{ rankdir: 'TB', nodesep: 60, ranksep: 80 }" />

Frequently Asked Questions about dagre-graph

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build hierarchical graph diagrams in Vue without manual node positioning?

You can build hierarchical graph diagrams in Vue by using DagreGraph components, which apply automatic ranking and edge routing to render directed graphs. This eliminates manual positioning by computing layouts for structures like org charts and flowcharts automatically.

What is a dagre layout used for when visualizing organizational charts?

A dagre layout is used for visualizing organizational charts by automatically arranging nodes into hierarchical levels and routing edges between them. It computes the visual structure from a simple data object, handling node separation and ranking direction.

Can I customize node shape and color in a Vue dependency graph visualization?

Yes, you can customize node shape and color in a Vue dependency graph visualization by using custom accessors. DagreGraph components support controlling visual properties like color, size, shape, and labels to fit specific dashboard requirements.

Does DagreGraph work with Vue-based dashboards for interactive flowcharts?

Yes, DagreGraph works with Vue-based dashboards for interactive flowcharts. It supports responding to node and link events, allowing you to build interactive decision trees and dependency graphs directly within Vue components.

How do I configure layout direction and spacing for a directed graph in Vue?

You configure layout direction and spacing for a directed graph in Vue by passing dagreSettings as a prop. Settings like rankdir for TB or LR direction, nodesep for node separation, and ranksep for rank separation control the visual output.

What data structure do I need to render a decision tree using DagreGraph?

To render a decision tree using DagreGraph, you need a data object containing nodes with id and label properties, and links with source and target identifiers. This single structure is passed to the component to generate the visual hierarchy.