D2 renderer adapter #8

Closed
opened 2026-06-16 14:48:16 +00:00 by GKaszewski · 0 comments
Owner

What to build

Add a D2Renderer adapter implementing DiagramRenderer. Produces D2 diagram language output, which has better layout control than Mermaid and renders to SVG.

D2 supports containers (for module grouping), classes with fields/methods, and styled edges — maps well to all three diagram levels.

Acceptance criteria

  • New adapter crate archlens-d2
  • Implements DiagramRenderer port
  • Renders project-level with containers for grouped crates
  • Renders module-level with dependency arrows
  • Renders type-level with class shapes showing fields/methods
  • --format d2 CLI flag works end-to-end
  • Tests verify D2 syntax output

Blocked by

None - can start immediately

## What to build Add a `D2Renderer` adapter implementing `DiagramRenderer`. Produces D2 diagram language output, which has better layout control than Mermaid and renders to SVG. D2 supports containers (for module grouping), classes with fields/methods, and styled edges — maps well to all three diagram levels. ## Acceptance criteria - [ ] New adapter crate `archlens-d2` - [ ] Implements `DiagramRenderer` port - [ ] Renders project-level with containers for grouped crates - [ ] Renders module-level with dependency arrows - [ ] Renders type-level with class shapes showing fields/methods - [ ] `--format d2` CLI flag works end-to-end - [ ] Tests verify D2 syntax output ## Blocked by None - can start immediately
GKaszewski added the P4 label 2026-06-17 06:46:20 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: GKaszewski/archlens#8