Hello guys,
My problem is that addMarkerCluster() does not work. Here is my code:
this.http
.get(link, headers)
.subscribe( data_ => {
this.healthList = JSON.parse(data_['_body']);
this.map.addMarkerCluster({
markers: this.healthMarkers_1,
icons: [
{min: 2, max: 100, url: "assets/icons/health_marker.png", anchor: {x: 16, y: 16}}
]
})
healthMarkers array consists of my markers:
$marker = array(
'title' => $row['title'],
'snippet' => $snippet,
'icon' => array( 'url' => 'assets/icons/municipality_marker.png' ),
'position' => array( 'lat' => $row['lat'] , 'lng' => $row['lng'] )
);
The strange thing is that when I take the same markers array from a local sqlite table, the addMarkerCluster works fine!!! Any ideas?? I waste one day for this!