d3-viz

Create custom interactive SVG data visualisations with d3.js in any JavaScript environment.

Updated Aug 12, 2026
One-click install
npx skills add https://github.com/Barbaros911/As-mine --skill d3-viz-barbaros911
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: d3-viz
Source: https://github.com/Barbaros911/As-mine/tree/main/.claude/skills/d3js-visualization
Command: npx skills add https://github.com/Barbaros911/As-mine --skill d3-viz-barbaros911

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires d3, and includes references (resource) and assets (resource) components.

What problem does it solve? Building bespoke charts, network diagrams, or geographic visualisations that go beyond standard charting libraries requires precise control over scales, layouts, transitions, and interactions, which is difficult to implement correctly from scratch. ## Core Features & Use Cases - Complete visualisation patterns: Ready-to-adapt code for bar, line, scatter, pie, chord, heatmap, treemap, sunburst, force-directed network, and choropleth visualisations. - Framework-agnostic integration: Two patterns covering direct DOM manipulation and declarative rendering for React, Vue, Svelte, or vanilla JavaScript. - Interactivity and polish: Guidance for tooltips, zoom, pan, brushing, transitions, responsive sizing with ResizeObserver, accessibility, and colour-blind safe palettes. - Use Case: A developer needs a force-directed network diagram with drag behaviour and tooltips inside a React dashboard; the skill provides the simulation setup, tick handler, and interaction code to adapt directly. ## Quick Start Ask the AI to create an interactive d3.js bar chart with tooltips and responsive sizing from your dataset.

Frequently Asked Questions about d3-viz

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

FAQPage Schema
How do I create a bar chart with d3.js?▼

Create a band scale for categories on the x-axis and a linear scale for values on the y-axis, then bind data to rect elements using .join(). Append axes with d3.axisBottom and d3.axisLeft inside a margin-offset group.

How to use d3.js with React or Vue?▼

Use d3 for scales and layout calculations while letting the framework render elements declaratively, or let d3 manipulate the DOM directly inside a ref or lifecycle hook. Clear previous renders with svg.selectAll("*").remove() before redrawing.

When should I use d3.js instead of a charting library?▼

Use d3.js for custom visual encodings, force-directed networks, geographic projections, choreographed transitions, or chart types unavailable in standard libraries. For 3D visualisations, use Three.js instead.

Does d3.js support responsive charts?▼

Yes, d3.js charts become responsive by listening to window resize events or using ResizeObserver on the container, then updating SVG width and height attributes and redrawing. Return a cleanup function to remove listeners when components unmount.

Why are my d3.js axes not appearing?▼

Axes fail when scales have invalid domains containing NaN values, when the axis is appended to the wrong group, or when transform translations are incorrect. Validate data with filters and check that domains use d3.max or d3.extent correctly.

How do I handle large datasets in d3.js?▼

For datasets over 1000 elements, render to canvas instead of SVG, use .join() instead of separate enter/update/exit selections, debounce resize handlers, and simplify paths. Quadtrees help with collision detection in dense layouts.