Shapes with SVG and CSS
✓ Published1🌍 Public
This example demonstrates how SVG shapes—circles, rectangles, lines, and paths—are drawn and styled using both inline attributes and external CSS. The SVG canvas is scaled and transformed, with some shapes inheriting default black fills while others use explicit `fill` colors or are grouped inside a `<g>` element that applies shared fill and stroke properties. A CSS class named `.lines` sets stroke color and width for the line and path elements, while the path also gets a custom stroke color and rounded line joins. The code uses raw SVG markup and CSS selectors, with no external libraries.
AI-generated descriptionA demonstration of basic HTML and CSS.
MIT Licensed