Skip to main content
100%

Fork of React & D3 Starter

✓ Published0🌍 Public
Bbillmccabeusa@hotmail.com
Last edited Nov 14, 2024
Created on Nov 14, 2024
Forked from React & D3 Starter

This example shows a scatterplot of the Iris dataset, mapping sepal length on the x-axis and petal length on the y-axis with semi-transparent circles. It demonstrates a decoupled React and D3 integration pattern for scalable projects. The React component `App` loads CSV data via a custom `useData` hook, while `VizWrapper` manages the SVG container and delegates rendering to a pure D3 `viz` function. D3's `scaleLinear`, `extent`, `axisLeft`, and `axisBottom` are used to compute scales and draw axes with SVG.

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