Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

d3 Data useState

Public visualization

Viewing a saved revision (read-only)

8a94dc2159084192be798cb44ef408f4

d3 Data useState

0 stars0🌍 Public
Mmartfhill
Last edited Jan 6, 2022
Created on Jan 6, 2022
Forked from Mouse Follower

This example demonstrates a React component that fetches a CSV file from a GitHub gist using D3's `csv` function, stores the resulting data in React state via `useState`, and then displays the raw data as large text in the browser. The visualization shows the parsed CSV data rendered directly as a string, with the code initiating the fetch within the component body and updating the state asynchronously. It uses React 17, D3 v7, and ReactDOM to render the `<App />` component into the HTML root element.

AI-generated description

Making a smiley face with React and D3