Skip to main content
100%

Fetch Data

✓ Published0🌍 Public
MMark Lam
Last edited Jul 15, 2021
Created on Jul 15, 2021
Forked from HTML Starter

This example demonstrates how to fetch and log CSV data in the browser console. The page displays the text “Fetch Data” at a massive font size, while the data loading happens behind the scenes. The code uses D3 v5’s `d3.csv` method to retrieve a CSV file of CSS named colors from a GitHub gist, then logs the parsed data array to the console. Alternative approaches using the Fetch API’s `fetch` with nested `.then()` calls or async/await are shown as commented-out examples.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.

MIT Licensed

Similar vizzes