How seeksdream/relation-graph works
Project type and purpose
• This is a multi‐platform front‑end component library (“relation‑graph”) published as a monorepo.
• Core purpose: render and interact with graph/relationship data in Vue 2, Vue 3, and React through a unified API and customizable slots.
File structure
• Top‐level directories:
• packages/ – the core code split by purpose:
– relation‑graph‑models/ (pure TypeScript models, layouters, utilities)
– platforms/ (framework adapters): react/, vue2/, vue3/
• play/ – demo applications for each platform (CDN‑demo, react‑demo, vue2‑demo, vue3‑demo)
• doc/ – documentation and demo images
• types/ – TypeScript declarations for consumers
• build‑and‑publish‑all.sh – monorepo release script
• Each platform folder contains: source components (canvas, graph, lines, nodes, editing controllers, widgets), build config (vite.config.ts), package.json.
• The models package contains: layout algorithms, graph data structures, utilities.
README for additional insights
• Confirms three published packages: “relation‑graph” for Vue 2, “relation‑graph‑vue3” for Vue 3, “relation‑graph‑react” for React.
• Highlights core API (setJsonData, event callbacks) and customization via slots/components.
• Links to live docs, demos, and a visual configuration tool hosted at relation‑graph.com.
Details
• Build and publication flow.
• How the same core can be extended via slots in different frameworks.
• That every major directory (packages/, play/, doc/, types/) is represented in the architecture.