Skip to main content
100%

Shapes with SVG and CSS

✓ Published1🌍 Public
Sshuksbhoney
Last edited Feb 12, 2022
Created on Feb 12, 2022
Forked from HTML Starter

This example shows a collection of geometric shapes—circles, rectangles, lines, and a path—arranged on an SVG canvas, with some shapes inheriting styles from CSS classes and groups. The SVG elements use direct attributes for fill, stroke, and positioning, while the `.lines` class applies stroke styling via CSS. The code uses vanilla JavaScript within an HTML page, linking to a separate stylesheet, and demonstrates how SVG and CSS work together without any external visualization libraries.

AI-generated description

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

See also React Starter.

MIT Licensed

Similar vizzes