Questions tagged [leaflet]

Leaflet is an open-source JavaScript library used to generate mobile-friendly interactive maps.

Filter by
Sorted by
Tagged with
1 vote
1 answer
95 views

First big project using vanilla js and pure css

If i can get a some reviews and suggestion on the code it would be highly appreciated. ( Please check the flowchart i've created first https://github.com/chetinn/Memory-Map-JS/blob/main/Memory%20Map%...
1 vote
0 answers
26 views

Filter and display dropdown based on data from API call

I have two functions: one fetch the API and get back the data (async function) the other use this data to filter and display information (dropdown function) The problem is the drop down function is ...
2 votes
0 answers
530 views

Create a map where countries can be selected using react-leaflet

I've only just started learning javascript and decided to try and make a simple app where individual countries can be selected, highlighting them, and the name appearing in the top corner. The code ...
0 votes
2 answers
71 views

Optimizing large WP Query [closed]

I have WP Query like this: ...
2 votes
2 answers
225 views

Speed up javascript code to convert csv to geojson

I'm using a script that converts a CSV file into GeoJSON in order to display it on a map. You can see it for yourself here. The CSV has about four thousand rows. It's quite slow. I'm wondering what is ...
4 votes
1 answer
31 views

Simple marker rendering

I am trying to render in a leaflet map that should render a single marker. I am building the JavaScript as follows. build the map an even listener for when the user opens the page where the map is ...
1 vote
1 answer
78 views

Leaflet map distance from the onclick marker

Here is the part of working code: ...
2 votes
1 answer
80 views

Setting zoom for layer disappearance in Leaflet

I have got 2 working codes, where one is a bit longer and another a bit shorter. Is it some way to bind all these layers as a one group? The first one is: ...
2 votes
1 answer
419 views

Loading KML files into leaflet Javascript map

This is working code for input KML files into leaflet map ...
4 votes
2 answers
137 views

Toggling visibility of layers on an interactive map

I am creating an interactive quad(heat) map of USGS Quadrangles wherein each quad has 12 different attribute fields CSV attached to the JSON using papa.parse. ...