Skip to main content

Polygon

You can use the polygon element to display a block of code.

Syntax

let elements = [
{
type: "polygon"
}
];

Rendered Element

The instance of Polygon class will be created.

new Polygon().set({
sides: 7,
size: 300,
background: "orange"
}).render("#mount");