Skip to main content
100%

Drawing SVG shapes with D3

✓ Published0🌍 Public
Aamitrumania-vcs
Last edited Jul 10, 2021
Created on Jul 10, 2021
Forked from Hello World

This example illustrates two methods for creating a blue SVG rectangle: a static, hand-coded SVG element and a dynamically generated rectangle via D3. The static bar is defined directly in the HTML markup, while the D3 bar is built by chaining `d3.select` and `.append` calls. The code uses d3.v7 to append an SVG and style the rectangle with a `fill` style, showing the same visual output achievable through both declarative and programmatic approaches.

AI-generated description

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

See also React Starter.

MIT Licensed

Similar vizzes