Skip to main content
๐ŸŒ Public

Share visualization

Send this visualization to others.

D3 tutorials

Public visualization

D3 tutorials

0 stars0๐ŸŒ Public
SSachin-jpg-lang
Last edited Mar 17, 2021
Created on Mar 17, 2021
Forked from HTML Starter

This example demonstrates a basic bar chart visualization. It shows a dataset of seven numeric values, each rendered as a fixed-width blue bar whose height corresponds to the value. The chart is built using D3.js methods to select the HTML body, append a `div` for each data point, and apply the CSS class `bar`. The bar heights are set inline using a JavaScript arrow function, and the initial styling is defined within a CSS style block. The code relies on `d3.select`, `d3.selectAll`, `.data`, `.enter`, `.append`, `.attr`, and `.style` to construct the visualization. The data is hardcoded as an array.

AI-generated description

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

See also React Starter.

Comments

Sign in to join the discussion.

MIT Licensed