{"id":254582,"date":"2017-05-08T07:11:20","date_gmt":"2017-05-08T14:11:20","guid":{"rendered":"http:\/\/css-tricks.com\/?post_type=chapters&p=254582"},"modified":"2021-10-06T07:36:58","modified_gmt":"2021-10-06T14:36:58","slug":"make-shape-draw","status":"publish","type":"chapters","link":"https:\/\/css-tricks.com\/books\/greatest-css-tricks\/make-shape-draw\/","title":{"rendered":"Self-Drawing Shapes"},"content":{"rendered":"\n
The best shape-drawing tool we have on the web is SVG, and in particular the Let’s say we have a single <path d=\"\" \/><\/code> element. With the path syntax<\/a>, you can draw anything you want with its commands for drawing straight and curved lines. A path can be a solid shape, but for our purposes here, let’s assume the path is
fill: none;<\/code> and we’ll focus on the
stroke<\/code> of the path and having that path draw itself. <\/p>\n\n\n\n
<path \/><\/code> that draws a cool shape like this:<\/p>\n\n\n\n