# Polygon

Shape from a bunch of points.

![Polygon example](../../../media/examples/polygon.png)


## Examples

```js
import { Polygon } from "pencil.js";

const points = [pointA, pointB, pointC];
const options = {
    fill: "red",
    stroke: "#000"
};
const polygon = new Polygon(position, points, options);
```


## PolygonOptions
Inherit from [ComponentOptions](../component/readme.md#componentoptions).

Polygon have no specific options.
