言栖资讯 / EnglishHow to draw any regular shape with just one JavaScript function2023-05-26来源 MDN BlogEnglishLearn how to use JavaScript to draw any regular shape to a HTML canvas with a single function, and how to modify it to draw multiple shapes.原文:https://www.a8q9.cn/en/article/how-to-draw-any-regular-shape-with-just-one-javascript-function-0e7c19.html