All Questions
37
questions
0
votes
0
answers
35
views
GeoJSON component not updating with state
I am having the following problem: although the filteredData is being updated, the Map doesnt reflect it.
This is the relevant code for my HOC (which contians the Map component):
const ...
1
vote
1
answer
88
views
How to Get GeoJSON Feature on Map.Locate in React Leaflet
I am creating a map with imported GeoJSON data. I am trying to create a Find Me button that will zoom to the user's location and get a property associated with the enclosing region (as defined by the ...
0
votes
2
answers
312
views
Type Error Importing GeoJSON file in a Typescript React App
I am trying to import a GeoJSON file to map region in a Leaflet map using React-Leaflet. I started the project using create-react-app. However, when I try to use the data in the GeoJSON component, I ...
1
vote
0
answers
514
views
Draw polygon from API Data using React-leaflet and click event
I'm using react-leaflet and Geoman, to draw polygons on the map, I have an API that provides me with a GeoJSON. I can draw the shapes easily using const polygon = L.polygon(props.coordinates).addTo(...
1
vote
3
answers
978
views
React Leaflet Geojson Tooltip. How to disable black borders on click or dragging?
I have problems with the library Leaflet. I have big JSON data, which renders and shows the borders of different districts.
I add a tooltip in my GeoJSon, it shows the name of this district. But when ...
0
votes
0
answers
153
views
GeoJson data is not being rendered over the react-leaflet map, when another shapefile is clicked
import React, { useState, useEffect, useRef } from "react";
import { MapContainer, TileLayer, GeoJSON } from "react-leaflet";
import "leaflet/dist/leaflet.css";
import ...
1
vote
1
answer
5k
views
How to render geojson polygon in React leaflet MapContainer?
Stack : Reactjs, Leafletjs, EsriLeafletjs
I am trying to display one Polygon in GeoJson on a leaflet map container. My main issue is when I use Leaflet.geoJson(data) it return invalid JSON object.
...
2
votes
3
answers
4k
views
Using Geojson with tons of data in react leaflet
I'm using GeoJson of react-leaflet to display all polygons of an area. However, when the amount of data increase to 10000, the performance turns bad and my app has performance issues, cause it slow ...
0
votes
1
answer
1k
views
How to refactor React Leaflet GeoJSON component to use the useMap function with Next.js?
I'm working on a React-Leaflet application using Next.js and I'm struggling to refactor my GeoJSON component to be able to implement a 'zoom to feature' event using the useMap function. The React-...
0
votes
2
answers
492
views
react-leaflet <GeoJSON /> pointToLayer option to change
I am learning react leaflet and trying to add circle marker on each point of geojson. Makers are not showing on map.
import React from 'react';
import Tiles from "./Tiles";
import L from '...
0
votes
1
answer
310
views
Use client side data fetching or getStaticProps for Leaflet layer component for SSG map with Next.js?
So, I'm trying to build a Next.js app to make a static site with a Leaflet map on it and I'm struggling conceptually with how to pull my location data into the components that will make up the Map. I'...
2
votes
0
answers
270
views
how to change color on Mouse over leaflet-react?
i'm facing a problem of mouseover event in leaflet
the thing is , when i hover ,the weight of the city changes for 2s and it doesn't stay highlighted even though the mouse is over the city
here is my ...
3
votes
0
answers
231
views
Use GeoJson data with Leaflet.PixiOverlay
I am using Leaflet.PixiOverlay(this package) in my App in order to render a big number of data(suck as markers, shapes, geoJson data, etc) without performance issues.
But the documentation of this ...
0
votes
0
answers
320
views
Can't display only one country with GeoJSON - React.js Leaflet
I use React-Leaflet and want to show only country one country .
I got geoJSON of country and gave style to it but other countries keep showing.
How may I hide or delete other countries ?
function ...
0
votes
2
answers
1k
views
React-leaflet performance issue, prevent GeoJSON re-render
I have the following issue:
I would like to create a simple choropleth map using react-leaflet's GeoJSON component. I also want to have a tooltip that shows a value on hover over a GeoJSON feature. ...