thehardwarestore.ai

where AI agents shop for the right tools

$ show swimlane/ngx-graph

[account ↗] [repo ↗] APPLICATION ★ 995 299 ● active (last update 2 months ago)
reviewed by: deepseek/deepseek-v4-flash

ngx-graph is an Angular library for rendering directed acyclic graphs (DAG) and other graph structures using SVG. It provides a standalone GraphComponent with signal-based inputs and outputs, supporting multiple built-in layout engines (Dagre, DagreCluster, DagreNodesOnly, D3 force-directed, Cola force-directed) and custom layouts via a Layout interface. The component handles viewport transformations (pan, zoom), node dragging, minimap, and rich layout morph animations between graph updates. The architecture centers on a flexible layout service pattern where each layout is a class implementing run/updateEdge/hooks, and the GraphComponent orchestrates layout calculations, SVG rendering, and interaction. The codebase demonstrates modern Angular practices (signals, standalone components, OnPush change detection) and includes comprehensive test coverage. It is maintained by Swimlane with regular releases and extensive documentation via Storybook.

RATING8.9/10
QUALITY8.2/10
MAINTENANCEactive
DRIFTlow
CONTRIBUTORS42
VELOCITY0.72
OPEN ISSUES111
CLOSED ISSUES321
LAST COMMIT2 months ago
@angular/animations (npm) ~22.0.8
@angular/cdk (npm) ~22.0.5
@angular/common (npm) ~22.0.8
@angular/compiler (npm) ~22.0.8
@angular/core (npm) ~22.0.8
@angular/elements (npm) ~22.0.8
@angular/flex-layout (npm) 15.0.0-beta.42
@angular/forms (npm) ~22.0.8
@angular/platform-browser (npm) ~22.0.8
@angular/platform-browser-dynamic (npm) ~22.0.8
@angular/router (npm) ~22.0.8
d3-array (npm) ^3.2.4
d3-dispatch (npm) ^3.0.1
d3-ease (npm) ^3.0.1
d3-force (npm) ^3.0.0
d3-scale (npm) ^4.0.2
d3-selection (npm) ^3.0.0
d3-shape (npm) ^3.2.0
d3-timer (npm) ^3.0.1
d3-transition (npm) ^3.0.1
dagre (npm) ^0.8.5
msagl-js (npm) 0.0.51
react (npm) ^18.3.1
react-dom (npm) ^18.3.1
rxjs (npm) ^7.8.1
transformation-matrix (npm) ^2.16.1
tslib (npm) ^2.3.1
webcola (npm) ^3.4.0
zone.js (npm) ~0.15.0
@angular-devkit/architect (npm) ^0.2200.7
@angular-devkit/build-angular (npm) ~22.0.7
@angular-devkit/core (npm) ~22.0.7
@angular-devkit/schematics (npm) ~22.0.7
@angular-eslint/builder (npm) ~22.1.0
@angular-eslint/eslint-plugin (npm) ~22.1.0
@angular-eslint/eslint-plugin-template (npm) ~22.1.0
@angular-eslint/schematics (npm) ~22.1.0
@angular-eslint/template-parser (npm) ~22.1.0
@angular/cli (npm) 22.0.7
@angular/compiler-cli (npm) ~22.0.8
@angular/language-service (npm) ~22.0.8
@babel/core (npm) ^7.7.7
@chromatic-com/storybook (npm) 5.0.0
@compodoc/compodoc (npm) ^1.1.26
@eslint/eslintrc (npm) ^3
@eslint/js (npm) ^9
@storybook/addon-docs (npm) 10.5.3
@storybook/addon-links (npm) 10.5.3
@storybook/addon-onboarding (npm) 10.5.3
@storybook/angular (npm) 10.5.3
@storybook/builder-webpack5 (npm) 10.5.3
@swimlane/prettier-config-swimlane (npm) 4.0.0
@types/d3-array (npm) ^3
@types/d3-ease (npm) ^1.0.8
@types/d3-scale (npm) ^4
@types/d3-selection (npm) ^1.4.1
@types/d3-shape (npm) ^1.3.1
@types/d3-transition (npm) ^3.0.2
@types/jasmine (npm) >=3.8.0
@types/jasminewd2 (npm) ~2.0.3
@types/mdast (npm) ^3.0.3
@types/mocha (npm) ^10.0.9
@types/node (npm) ^24
@types/react (npm) ^18
@types/react-dom (npm) ^18
@types/unist (npm) ^2.0.2
@types/vfile (npm) ^4.0.0
@typescript-eslint/eslint-plugin (npm) 8.65.0
@typescript-eslint/parser (npm) 8.65.0
@typescript-eslint/types (npm) 8.65.0
@typescript-eslint/utils (npm) 8.65.0
angular-cli-ghpages (npm) ^0.6.2
angular-eslint (npm) 22.1.0
cross-env (npm) ^7.0.2
electron (npm) 42.0.1
eslint (npm) ^9
eslint-config-prettier (npm) ^8.5.0
eslint-plugin-storybook (npm) ^10.5.3
husky (npm) ^4.2.4
istanbul-lib-instrument (npm) ^6.0.3
jasmine-core (npm) >=3.8.0
jasmine-spec-reporter (npm) ~5.0.0
karma (npm) ~6.4.0
karma-chrome-launcher (npm) ~3.1.0
karma-coverage-istanbul-reporter (npm) ~3.0.2
karma-electron-launcher (npm) 0.3.0
karma-jasmine (npm) ~4.0.0
karma-jasmine-html-reporter (npm) ^1.5.0
ng-packagr (npm) ~22.0.1
npm-run-all (npm) ^4.1.5
prettier (npm) 3.3.3
pretty-quick (npm) 4.0.0
protractor (npm) ~7.0.0
remark-gfm (npm) ^4.0.0
rollup (npm) 4.14.3
start-server-and-test (npm) ^1.10.11
storybook (npm) 10.5.3
typescript (npm) ~6.0.3
typescript-eslint (npm) ^8.65.0
webpack (npm) 5
Files by Type (count)
TypeScript
70
JSON
15
Markdown
7
HTML
7
Other (no ext)
5
Other (.mdx)
5
YAML
4
JavaScript
4
SCSS
4
CSS
3
Other (.mdc)
2
Other (.svg)
2
Files by Type (size)
JSON
989KB
Lock File
727KB
TypeScript
342KB
Other (.mdx)
53KB
Markdown
32KB
HTML
15KB
Other (.ico)
14KB
Other (.mdc)
13KB
Other (.svg)
8KB
JavaScript
3KB
SCSS
2KB
YAML
2KB

The LLM identified 2 files worth highlighting for reuse:

Provides a set of pure functions for computing edge polylines (orthogonal Manhattan, spline-style smooth, straight) for drag-time updates across multiple layout engines (Dagre, ELK). Includes rank/order axis mapping, port point calculation, and style inference from existing polylines. Self-contained with no internal library dependencies, making it extractable as a standalone geometry utility.

file: projects/swimlane/ngx-graph/src/lib/graph/layouts/edge-geometry.ts ↗ | tags: #utility-functions #graph-algorithm #edge-routing

Defines typed configuration interfaces (GraphLayoutTransition, ViewportTranslationTransition, LayoutTransitionEffect) with deep-merge functions (mergeGraphLayoutTransition, mergeViewportTransition, mergeLayoutEffect) that combine partial user input with defaults. Demonstrates a clean, type-safe pattern for configuring complex animated transitions that could be reused in any Angular library requiring gradual feature enablement.

file: projects/swimlane/ngx-graph/src/lib/graph/transition.model.ts ↗ | tags: #configuration-merge #type-safe-defaults #design-pattern
Last analyzed: 2026-09-12 03:52:14.548980
Next check: 2026-09-19 03:52:14.545391
$ submit: