Is someone familiar with this library?: https://angular-maps.com/ If so can someone help me creating a click event on the marker i tried this:
<sebm-google-map-marker *ngFor="#location of locations" (click)="updateDiv()"
[latitude]="location.lat" [longitude]="location.lng" [label]="location.id">
updateDiv() {
console.log('check');
}
But it seems not to work? What am I doing wrong?
I think that you could try the following (markerClick
event instead of the click
one):
<sebm-google-map-marker *ngFor="#location of locations"
(markerClick)="updateDiv()" [latitude]="location.lat"
[longitude]="location.lng" [label]="location.id">
updateDiv() {
console.log('check');
}
See this doc in the Outputs section:
You need to use markerClick
instead of click
like this:
(markerClick)="updateDiv()"
See also documentation https://angular-maps.com/docs/api/latest/ts/core/SebmGoogleMapMarker-directive.html#Outputs
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With