I am working with angular 7 and leaflet js for the map representation.

I want to navigate to another page when click on the marker. But routing is not working properly.

eg:

```
L.marker.on('click', function(){
    this.router.navigateByUrl('/dashboard');
});

```

when click on the marker, the url changed to '/dashboard' but the map still showing in the page.

when click on the html element, navigation working fine.

Could any one please help me on this.

Thanks in advance