Skip to main content
100%

Loading data with React

✓ Published0🌍 Public
KkyleSpaulus
Last edited Aug 3, 2023
Created on Aug 3, 2023

This example demonstrates how to load and summarize a CSV dataset using D3 within a React application. It displays the file size in kilobytes, row count, and column count in a large `<pre>` element. The React component uses the `useState` and `useEffect` hooks alongside `d3.csv` to fetch and parse the data from a GitHub gist. The `message` helper function calculates the summary using `d3.csvFormat` to determine the formatted data length.

AI-generated description

Program to follow mouse pointer

MIT Licensed

Similar vizzes