{"version":"1.0","type":"rich","title":"Loading Data with d3 & React","description":"This example demonstrates how to load CSV data asynchronously in a React component using d3.csv, displaying the dataset’s size, column count, and row count in a large <pre> element. The React useState hook manages the fetched data, initially showing a “loading” message until the promise resolves. The code imports ReactDOM and d3’s csv parser directly from CDN links. The data originates from a GitHub gist containing CSS named colors. The output updates responsively once the fetch completes, converting the parsed CSV back to text with d3.csvFormat to calculate its kilobyte size.","provider_name":"VizHub AI Studio","provider_url":"https://vizhub.com","html":"<iframe src=\"https://vizhub.com/viz/ceeb607c1a8f4aa9bc9ef5ba92f6de12?mode=embed\" width=\"960\" height=\"500\" scrolling=\"no\" frameborder=\"0\"></iframe>","width":960,"height":500,"cache_age":3600}