Skip to main content

All Questions

1 vote
2 answers
314 views

React Leaflet update position

I've got a question about React Leaflet. I am now trying to build a PWA with the react framework and I need to use a map, hence React Leaflet. So here's the situation : I need to load the Map when I ...
1 vote
2 answers
196 views

React Leaflet markers not rendering with location data fetched from an API using useEffect

I am trying to render leaflet markers using React Leaflet with data fetched from an API using useEffect. The markers are not showing up despite the location data being non-null at the time of ...
0 votes
1 answer
75 views

Hide rest of map around country with leaflet.js in next js

I need help please. I would like to hide the other maps and only show the one of Cameroon. I'm using Leaflet and I'm on Next.js to be able to display the map. I saw this page React-Leaflet 4 with ...
0 votes
1 answer
74 views

Next.js React-Leaflet bouncing marker using Leaflet.SmoothMarkerBouncing

I am new to the front-end development, I am trying to get bouncing marker in React-leaflet using https://www.npmjs.com/package/leaflet.smooth_marker_bouncing/v/1.3.0?activeTab=explore But I don't have ...
0 votes
3 answers
166 views

Smooth scroll with react-leaflet

I'm trying to create a smooth zoom in my react-leaflet project. I know that this is doable with vanilla leaflet as said in this post, with smoothWheelZoom, but knowing that vanilla leaflet does not ...
0 votes
0 answers
71 views

Leaflet Map Rendering Issue with Large Non-Geographical Map

I’m currently developing a non-geographical map for my website using React, tailwindCSS and react-leaflet. The map is square-shaped and quite large, with each side measuring 10 million pixels. The ...
0 votes
1 answer
101 views

react-leaflet-heatmap-layer-v3 src directory not found

Trying to use the npm library react-leaflet-heatmap-layer-v3 and after I install it successfully and then yarn start my react typescript app, I get the following warning messages: WARNING in ./...
15 votes
4 answers
11k views

Leaflet React get map instance in functional component

I want to have a button outside the map that changes the view to another coordinates. Is there any way to get mapContainer instance to call their functions? Or how can I implement that function? 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:\...
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 ...
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 ...
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' ...
2 votes
1 answer
345 views

How to add react-leaflet map to remixjs app

I'm trying to add a react-leaflet map to a remix app. I created a simple app using the npx create-remix@latest command. I then added react-leaflet using the installation instructions. Now I have ...
0 votes
1 answer
300 views

Problem with using google earth engine api with react

I am creating a react app with google earth engine API and leaflet with a Django backend. The backend will be used for computer vision purposes, Google earth engine is to be used to add layers to the ...
0 votes
1 answer
126 views

want to show pin on leaflet map using react js

I am trying to create a map using React JS and a leaflet but the problem is I am not able to map position on the map here is my code import React, { useState } from 'react'; import { MapContainer, ...

15 30 50 per page
1
2 3 4 5
35