All Questions
25
questions
1
vote
1
answer
43
views
Get Coords from LeafletMouseEvent
I am trying to get coords from a leaflet map. I tried using e.latlng but it only returns the coords i initialized the map with. Not sure what's not working honestly.
Here is my code:
private map: L....
0
votes
2
answers
120
views
Issue with SCSS Styling in Leaflet Map with OpenStreetMap
Issue with SCSS Styling in Leaflet Map with OpenStreetMap
I'm using OpenStreetMap and Leaflet to draw on a map. I have a function updateMarkers() that clears existing markers and creates new ones ...
0
votes
0
answers
175
views
Leaflet antpath error "Property 'antPath' does not exist on type"
I am doing a leaflet demo with angular 16. I have installed the leaflet package and it works perfectly but I can do the antpath polyline (The polyline works fine tho).
Steps I've done:
• npm install ...
0
votes
1
answer
370
views
Get data from geojson file based on current marker location
I need to superimpose polygons on leaflet map based on the data in the geojson file as I need to display custom location names for areas. This geojson file contains co-ordinates of polygon along with ...
0
votes
1
answer
1k
views
Do I need to set up my own OSRM server while using OSRM leaflet-routing-machine to display coordinates saved on DB snapped to road?
Ok so in my angular app I am working on the frontend I have two dropdown in which I specify the city of departure and arrival and the backend uses an api that calculates the coordinates of this two ...
3
votes
0
answers
1k
views
Display ECharts map using OpenStreetMap without Leaflet
I would like to render a geographical map inside my web page using the ECharts library.
ECharts needs a third party service to retrieve the images of the geographical region that it must display and I ...
0
votes
1
answer
852
views
Get Leaflet map tile image for polygon
For a project I need to generate previews of polygons that we store in the backend. A polygon typically has this format: [lat,long]
const polygon = [
[
4.329064,
51.276626
],
...
0
votes
1
answer
2k
views
How to integrate offline maps in Ionic+Angular using leaflet maps?
this.map = leaflet.map("mapId", { zoomControl: false }).setView([17.385, 78.4867], 13);
leaflet.tileLayer("https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png", {
...
0
votes
0
answers
275
views
How to include the leaflet map in angular formly with custom component
I have to create the leaflet map where I have used the angular formly .
and I have created the custom component for leaflet map as
leaflet.component.ts
import { Component, OnInit } from '@angular/core'...
0
votes
0
answers
293
views
How to integrate the leaflet map in angular
I want to show the leaflet map in angular application
As I have used the angular formly for application with tabs because In my application I have to create the dynamic forms
In third tab I have to ...
0
votes
1
answer
411
views
moving marker does not exist on type of import
moving marker does not exist on type of import please help me to solve this error.
I have installed npm package npm install --save leaflet-moving-marker
but it shows the error
moving marker does not ...
1
vote
2
answers
992
views
How to create the multiple leaflet maps on the page in angular
I have created the leaflet open street map given below.
.component.ts
map = L.map('map').setView([12.876, 80.599], 12);
L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
...
0
votes
1
answer
435
views
Leaflet + Angular is it possible to draw semicircles?
In my angular application, I use maps through the ngx-leaflet library and openstreet maps. And now we need to draw semicircles.
I know there is a Leaflet-semicircle extension, but I have already ...
-1
votes
1
answer
64
views
launch navigator with a FAB
hello to those who see this, I'm a beginner in typescript development so i try my best I'm trying to launched a navigator (like waze, gmap or other...) with a FAB. this is my code in TS:
ngOnInit() {
...
0
votes
1
answer
665
views
Add marker on Leaflet map from another angular component
I have declared, in my Angular application, a const map variable in my mapComponent and I am able to add custom marker on map in the same component; how can I do the same thing from other Angular ...
0
votes
0
answers
176
views
How to find multiple markers?
I am trying to find a way to use multiple markers on an OSM map. In spite of a frightening number of tutorials, I am unable find a solution to recover the info (longitude, latitude of locations) in ...
0
votes
1
answer
1k
views
Changing the Center of a leaflet open street map
I'm initializing a map using leaflet(openstreetmaps) in angular and setting a center that the user sees when opening the site. How can i change the center so the map rotates to the new coordinates on ...
2
votes
1
answer
4k
views
How do I reset the view of my map back to my location in Ionic with Leaflet and OpenStreetMap?
Right now I'm working on a locationbased App in Ionic v4. Now I want to be able to reset the map view back to my location. I guess I need to use setView again to achieve this, but I don't know the ...
0
votes
1
answer
3k
views
Add leaflet ImageOverlay to Layers Control
I use leaflet with the Angular package ngx-leaflet and just trying to get my layer for ImageOverlays in my LayersControl, so I can show or hide this layer in the map based on a checkbox. Somehow it ...
0
votes
1
answer
2k
views
How to add pulse animation in asymmetric on marker
I`ve problem with adding animation on marker in leaflet lib
I use
new L.Icon({ iconUrl: 'https://cdn.rawgit.com/pointhi/leaflet-color-markers/master/img/marker-icon-2x-green.png',
shadowUrl: '...
1
vote
1
answer
1k
views
Access Leaflet map in different component in Angular
I have a component, OpenStreetMapComponent, which views my whole map. In the same component I also have a number of buttons (zoom, current location...). Having all of that in one component soon makes ...
1
vote
1
answer
1k
views
set current Location marker
I worked through this tutorial and got it all up and running. Now I want to get my current browser Location and set a marker for it onMapReady. I am pretty new to programming and I'm just starting to ...
2
votes
1
answer
1k
views
Leaflet map double marker issue
I am building an ionic3 app and using leaflet for the map functions. However i encountered a strange behavior. After page load the location is automaticly fetched if GPS is turned on. After this for a ...
2
votes
2
answers
900
views
Preformance of leaflet with angular2
I'm trying to load lot's of marker on a leaflet map
With this method :
L.marker([item.latitude, item.longitude]).addTo(this.map);
I loop for at least 100 markers and the map become really laggy ...
1
vote
0
answers
602
views
Adding leaflet markers dynamically from an MeteorObservable in Ionic2
I am in an Ionic2 / Angular2 typescript project. I want[1] to use leaflet and it's working quite fine, I can do all the basic operations like adding/editing markers and so on.
But as a next step I ...