Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Loading and Parsing Data

Public visualization

Viewing a saved revision (read-only)

2e1f8dbe1c7f4f06b753a1e8980eaff6

Loading and Parsing Data

0 stars2🌍 Public
CCurran Kelleher
Last edited Jul 9, 2025
Created on Jul 1, 2025

This example demonstrates asynchronous data loading and parsing in a React-free D3 visualization, showing a loading indicator before rendering clickable circles from a CSV file. Using d3-rosetta's unidirectional data flow and `createStateField`, it manages state transitions from loading to succeeded or failed. When data arrives, `d3.csv` parses the x and y columns, then `renderCircles` draws circles that respond to clicks via `setupClickInteraction`, with `highlightSelectedDatum` visually distinguishing the selected point.

AI-generated description