🌍 Public
Viewing a saved revision (read-only)
4d68517af1c644cdb14cee406cc66a87
Making a Line Chart
This example demonstrates how to build a line chart in React, showing temperature over time for a week in San Francisco. The chart uses D3’s scales (`scaleTime`, `scaleLinear`) and line generator (`line()` with `curveNatural`) to draw a smooth path, while custom React components (`AxisBottom`, `AxisLeft`, `Marks`) render SVG axes and the curve. Data is loaded asynchronously via `d3.csv` from a remote URL.
AI-generated description