# Marker Cluster BUG

**URL:** <https://community.appfarm.io/t/marker-cluster-bug/1355>\
**Category:** Bug reports\
**Created:** [August 28, 2024, 7:21am UTC](https://community.appfarm.io/t/marker-cluster-bug/1355 "2024-08-28T07:21:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![SinanMaric](https://dub1.discourse-cdn.com/flex013/user_avatar/community.appfarm.io/sinanmaric/32/1226_2.png) [@SinanMaric](https://community.appfarm.io/u/SinanMaric)\
**Post date:** [August 28, 2024, 7:21am UTC](https://community.appfarm.io/t/marker-cluster-bug/1355/1 "2024-08-28T07:21:49Z")

</div>

I am using an Appfarm map component in one view, and a coded component using Leaflet code to interact with a map in another view.

When navigating from the coded component view to the Appfarm map the site crashes and I get error:

```auto
Name
TypeError

Message
L.MarkerClusterGroup is not a constructor

Trace
TypeError: L.MarkerClusterGroup is not a constructor
    at L.markerClusterGroup

```

So I saw that we had Clustering enabled on the markers in the Appfarm map. When I disabled this the error was fixed. So, I assume there are some Appfarm bug. Just wanted to let you know.

---

<div class="post-metadata">

**Author:** ![ErikAKSkallevold](https://dub1.discourse-cdn.com/flex013/user_avatar/community.appfarm.io/erikakskallevold/32/1378_2.png) [@ErikAKSkallevold](https://community.appfarm.io/u/ErikAKSkallevold)\
**Post date:** [August 28, 2024, 8:15am UTC](https://community.appfarm.io/t/marker-cluster-bug/1355/2 "2024-08-28T08:15:18Z")

</div>

Hi,

I was unable to recreate the issue in our Dev Environment.  
I have however registered a challenge on the issue. If you have anymore details, then please let us know 🙂

Are you 100% sure that error is not thrown by the Leaflet code in your Coded Component. It seems like both your Coded Component and Appfarm uses Leaflet for maps.

// Erik
