/leaflet-piechart

Pie chart marker for Leaflet library. Intention to add the doughnut charts as markers on Leaflet Maps

Primary LanguageJavaScript

Leaflet Charts

Hits

Pie Charts

Just add the pie chart marker using the basic code:

L.piechartMarker(L.latLng([lat, long]), {
  data: [
    { name: "Apples", value: 25 },
    { name: "Oranges", value: 35 },
    { name: "Bananas", value: 20 },
    { name: "Pineapples", value: 30 },
  ],
}).addTo(map);

The pie charts look like:

Doughnut Charts

Just add the doughnut chart marker using the basic code

L.doughnutchartMarker(L.latLng([lat, long]), {
  data: [
    { name: "Apples", value: 25 },
    { name: "Oranges", value: 35 },
    { name: "Bananas", value: 20 },
    { name: "Pineapples", value: 30 },
  ],
}).addTo(map);

The doughnut charts look like: