Skip to main content
100%

Fork of React & D3 Starter

✓ Published0🌍 Public
Ttaniafgithub
Last edited Aug 16, 2023
Created on Aug 16, 2023
Forked from React & D3 Starter

This example demonstrates a reusable starter pattern for integrating React with D3.js, displaying the classic Iris dataset as a scatterplot. The visualization maps sepal length and petal length onto x- and y-axes using D3’s `scaleLinear` and `extent`, with circles rendered via SVG. React manages the component lifecycle through hooks like `useState`, `useEffect`, and `useRef`, while D3 handles selection, data joins, and axis generation with `axisLeft` and `axisBottom`. The code showcases decoupled architecture, scaling for complexity, and copy-paste compatibility with existing projects.

AI-generated description

This viz is a starter that demonstrates patterns used in real world projects in which complexity is anticipated to scale.

  • Decoupled React & D3 integration
  • Opening moves for scalable complexity
  • Industry standard ES modules and JSX
  • Copy-paste into existing projects

Any questions? Ask on Twitter!

Also viewable in:

MIT Licensed

Similar vizzes