# Polygon

> An SVG polygon element.

- Category: [Text & media](https://tarve.dev/docs.md#text-media)
- Import: `import { Polygon } from "@tarve/core";`
- Source: [packages/core/src/components/svg.ts:52](https://github.com/omarcosr/tarve/blob/main/packages/core/src/components/svg.ts#L52)

## Usage

```tsx title="Polygon.tsx"
import { Polygon, Svg } from "@tarve/core";

<Svg viewBox="0 0 24 24" size={64} fill="#fbbf24" stroke="none">
  <Polygon points="12 2 15 9 22 9 16.5 13.5 18.5 21 12 16.5 5.5 21 7.5 13.5 2 9 9 9" />
</Svg>
```

## Props

Polygon has no props of its own beyond the inherited and common props below.

### Inherited from `PolygonProps`

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `points` (required) | `string` | — |  |

Previous: [Polyline](https://tarve.dev/docs/components/Polyline.md) · Next: [SvgRect](https://tarve.dev/docs/components/SvgRect.md)

---

Tarve v0.13.8 · HTML version: https://tarve.dev/docs/components/Polygon · Index for agents: https://tarve.dev/llms.txt
