All Questions
1,096
questions
0
votes
0
answers
23
views
React with Leaflet: issue color coding map based on country specific data
Essentially, I would like to be able to click a country and see it's trade partners highlighted on the map. I know that I am reading the data corrrectly from the ISO3, and I am able to print it, I ...
0
votes
1
answer
65
views
Window not defined on build NextJS
I am getting a window not defined error? I do not call window or document anywhere in the code and it works fine in development just errors on build.
ReferenceError: window is not defined
at C:\...
-1
votes
1
answer
36
views
React re-renders everything
I have an array of markers on a map using leaflet. I want to be able to remove one of the markers, however when I update the array of markers, it re-renders ALL of the markers in the array as you ...
0
votes
1
answer
107
views
Getting the clicked marker in react leaflet
So I have my leaflet map in my react project, I have markers on this map and I want to get the marker clicked. I want to show this markers popUp info on a side panel. How would I get the marker ...
0
votes
0
answers
82
views
How to manage rendering 30000 polygons on map using react-leaflet?
Im using react-leaflet to render heatmap using big amount of polygons that I get from database. Polygons are preconfigured and I don't perform any actions on them. My issue is that when user wants to ...
0
votes
0
answers
19
views
how to do autosave on editvertex ? because i dont want user to save all the time when he/she edits
Just want to save the polygons even after not saving it , and i have hided the save and cancel button.
Im already rendering the polygons using my own state and im changing it on every vertex change ...
0
votes
1
answer
77
views
changing cluster's styles not working with lazy loading leaflet in SSR react application
I'm encountering some challenges with lazy loading a Leaflet map in a React application deployed on a server-side rendering (SSR) environment. The application involves loading a list of products in a ...
0
votes
1
answer
60
views
how to do it in openlayer like leaflet draw style editor
I have researched and searched many times and can't find examples of style editors on openlayers. Available only on leaflets. Please share your experience, how should I write it?
It's fine if you ...
0
votes
1
answer
111
views
React-leaflet flyto new position
I have a rather large application based on react and leaflet.
The problem is that I can't get the main map of the code to move to a new location, provided by the user in an input menu, when the menu ...
1
vote
2
answers
4k
views
How to show only one country using react leaflet?
I'm using react-leaflet in one of my projects and I want to show only one country and delete the rest or hide.
Someone has solved this problem but unfortunately it's not for React. Do you know how to ...
1
vote
1
answer
2k
views
How to open a specific popup on map load?
Using React-Leaflet V3.1.0 with an Express server.
My users have requested the ability to use a link in the following format:
https://www.mymap.com/id/:category/:id/:zoom
This sends a request to the ...
57
votes
7
answers
99k
views
Leaflet: Map container not found
I have the below react class which fetches the geolocation through the browser.
I am mapping a leaflet map. I want to geolocation to be an input to the setView, for such that the map "zooms" into the ...
4
votes
0
answers
1k
views
React leaflet WMSTileLayer with custom request headers
I am trying to send authentication header with my wms tile requests.
When I used pure leaflet library it was very simple using leaflet-wms-header
But, I have switched to react-leaflet and it has its ...
91
votes
19
answers
85k
views
react-leaflet map not correctly displayed
I'm trying to use react-leaflet to display a map. I use the code from this fiddle which is working, but on my computer I have this output
Here is my code :
DeviceMap.js
import React from 'react'
...
0
votes
0
answers
70
views
flyTo of react leaftlet working while setView is not react leaflet
I'm building this "Contacts" page that gets some locations from supabase displays them on the map and at the same time displays their information in a ul.
Now everytime the user clicks on a ...