---
layout: api
title: "v2.1.8 JavaScript Library: L.Polygon"
categories: api
version: v2.1.8
permalink: /api/v2.1.8/l-polygon/
---
<h2 id="polygon">Polygon</h2>

<p>A class for drawing polygon overlays on a map. Extends <a href="/mapbox.js/api/v2.1.8/l-polyline">Polyline</a>. Use <a href="/mapbox.js/api/v2.1.8/l-map">Map#addLayer</a> to add it to the map.</p>

<p>Note that points you pass when creating a polygon shouldn't have an additional last point equal to the first one &mdash; it's better to filte