Skip to main content
100%

Shapes with SVG and CSS

✓ Published1🌍 Public
MManoj
Last edited Mar 20, 2023
Created on Mar 19, 2023
Forked from HTML Starter

This example demonstrates how to create shapes using SVG elements styled with CSS. It shows circles, rectangles, lines, and a path rendered on a 960x500 canvas, with CSS classes controlling stroke properties like color and width. The code uses inline SVG attributes for basic positioning and fill colors, while the `lines` class applies black strokes and a yellow stroke with round line joins to the path. The `g` element groups shapes and applies a translation transform, and the CSS resets body margins and hides overflow.

AI-generated description

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

See also React Starter.

MIT Licensed

Similar vizzes