Ask for help with the project map Todo, currently writing in native java script.

2021.11.28 11:45 ewaldborsodi Ask for help with the project map Todo, currently writing in native java script.

Hello, I'm currently working on dev mini app with google map inserted and set locations that you can visit in my country. I placed the pins on the map and clicking on it opens a pop up window with additional information. I should make it now a button that should take you to next closest location relative to the current one where the user is located ? I was thinking how it could be and I thought should have some loop through which go and then return the nearest location?
This is what these objects(locations) in map.js look like:

const bhLocations = [ { name: "Jevrejsko Groblje", lat: 43.85006694816966, lng: 18.407905721139482, imgUri: "./images/jevrejsko-groblje.jpg", tags: ["cemetery", " architecture", " jewish culture"], }, { name: "Kriva Ćuprija", lat: 43.33688774764681, lng: 17.81310416859141, imgUri: "./images/krivcup1.jpg", tags: ["bridge", "architecture", "ottoman"] }, { name: "Ključka Tvrđava", lat: 44.53952184140635, lng: 16.78572578942711, imgUri: "./images/kljuckat.jpg", tags: ["fotress", "castle", "history"], }, { name: "Motajica", lat: 45.113701045483865, lng: 17.656291396935696, imgUri: "./images/motajica.jpg", tags: ["mountain", "nature", "hiking"], }, { name: "Ozren", lat: 44.614348741483134, lng: 18.25332260726994, imgUri: "./images/ozren.jpg", tags: ["mountain", "nature", "hiking"], }, ... { name: "Kula Grad kod Zvornika", lat: 44.369330957742555, lng: 19.092613821039716, imgUri: "./images/kula-zvornik.jpg", tags: ["castle", "medieval", "fortification", "history"], }, { name: "Vrelo Bosne", lat: 43.8212512423983, lng: 18.267515809645214, imgUri: "./images/vrelo-bosne.jpg", tags: ["spring", "nature preserve", "park" ], 
there are about 80 of these made.
and this is the logice I have written above in same file (map.js):
let map; async function initMap() { const startPosition = { lat: 43.85006694816966, lng: 18.407905721139482, }; var map = new google.maps.Map(document.getElementById("map"), { center: startPosition, zoom: 7, }); let infowindow = new google.maps.InfoWindow(); for(let i=0;i'; infoImg += '' infoImg += '

' + bhLocations[i].tags.join(" - ") + '
'; infoImg += ''; let textNode = document.createElement('div'); textNode.innerHTML = infoImg; infoWindowNode.append(textNode); infowindow.setContent(infoWindowNode); infowindow.open(map, marker); } })(marker, i)); }; }

submitted by ewaldborsodi to reactjs [link] [comments]


2021.11.28 11:45 dunkin1980 Elon Musk urges Tesla employees to reduce cost of vehicle deliveries

Elon Musk urges Tesla employees to reduce cost of vehicle deliveries submitted by dunkin1980 to elonmusk [link] [comments]


2021.11.28 11:45 ImportanceSilver3251 Milan 1 - [2] Sassuolo - Gianluca Scamacca 33'

submitted by ImportanceSilver3251 to soccershighlights [link] [comments]


2021.11.28 11:45 GinjaNinja1027 You know whether or not somebody around you has looked at porn in the last 24 hours.

submitted by GinjaNinja1027 to shittysuperpowers [link] [comments]


2021.11.28 11:45 TrueSector6 This Nfs support ultra wide 21:9 ???

This Nfs support ultra wide 21:9 ???
https://preview.redd.it/fzydlmhpmc281.png?width=1533&format=png&auto=webp&s=68d6b15d91dcc20dee9105d8fd7d4706602470e6
submitted by TrueSector6 to needforspeed [link] [comments]


2021.11.28 11:45 Crazzaklok Mod version conflict client showing current version, server showing 0.0.0

Currently working on getting Legundo's Galar Modpack to work on a server but im having some issues. I can get the server up and running but ill have the following mods say that there are version issues: Arcanus, Caracal mob, Caves and Cliffs add-on for William Wythers Overhauled Overworld, Clean Cut, Illuminations, On Soul Fire, Stoneholm, The Graveyard, William Wythers Overhauled Overworld, and YUNG's (API, Better Dungeons, and Better Mineshafts) Do these mods just not work on a server or am i just an idiot. Also yes I am newer to running modded servers and mainly have worked with Forge not Fabric. I do have alot of errors and warnings in the logs but nothing that i can see that would stop these from running specifically looking at YUNG's i can comment some log information if desired.
submitted by Crazzaklok to fabricmc [link] [comments]


2021.11.28 11:45 waheyguru PC booting into BIOS after upgrading parts

So I changed my CPU from Ryzen 5 1600 to Ryzen 5 5600x (MSI B450 TOMAHAWK) I updated BIOS to the latest version before installing everything using BIOS Flashback. I also upgraded to EK 360MM AIO, Lian li o11 dynamic XL so I had to rebuild my PC from the start into the new cabinet. After assembly the PC starts normally but it straight up boots into BIOS, i tried to choose the boot drive manually but no drive shows up. The motherboard's debug LED is red on the "boot". It would be great if anyone helps me figure out that what i need to do to get my PC to boot to Windows. Thanks
I know for sure that the PC will work when i reinstall windows but i want to backup before reinstalling to windows 11.
submitted by waheyguru to buildapc [link] [comments]


2021.11.28 11:45 Amell-UC Why ..

Why .. submitted by Amell-UC to GBO2 [link] [comments]


2021.11.28 11:45 guicadioli Post para agradecer a namorada do Deyverson que não deixou ele ir para China

Obrigado.
submitted by guicadioli to palmeiras [link] [comments]


2021.11.28 11:45 emo371tbh Rise of the Resistance

I am going to east on Tuesday and haven’t been there since June when the virtual queue was still running. Now that it’s just a standby line, does anyone have advice on how to avoid a long wait time? I’ve been checking the wait times and they range from an hour to 4 hours. Is it better to just get the Lightning Lane? Or is there a certain time where it would be worth it to just wait in line? Thanks
submitted by emo371tbh to GalaxysEdge [link] [comments]


2021.11.28 11:45 probablyirishroyalty Gophers take back the axe and play House of Pain as fans storm the field and ... Jump Around!

Gophers/badgers is the oldest rivalry in major college football and this has got to be the funniest trolling so far.
submitted by probablyirishroyalty to minnesota [link] [comments]


2021.11.28 11:45 kcgarbin Oh, is this a pattern I see here?

Oh, is this a pattern I see here? submitted by kcgarbin to memes [link] [comments]


2021.11.28 11:45 _MACHINESbuilder_ Hey, where I can see the evolution trees of species?

submitted by _MACHINESbuilder_ to NoStupidQuestions [link] [comments]


2021.11.28 11:45 shivamYe A statement from Williams Racing

A statement from Williams Racing submitted by shivamYe to formula1 [link] [comments]


2021.11.28 11:45 Sky_Office Too cold for Norwegians to ski…

Too cold for Norwegians to ski… submitted by Sky_Office to Norway [link] [comments]


2021.11.28 11:45 kamdub1775 World's Most Crowded Train

World's Most Crowded Train submitted by kamdub1775 to YouTubePromoter [link] [comments]


2021.11.28 11:45 entrelineas_org Salvador Dali, Boris Karloff y Frank Sinatra fueron los jueces que eligieron de entre 500.000 propuestas el dibujo de Basil Wolverton #BasilWolverton #Dibujantes #CienciaFicción #Grotesco #Futuro #Catástrofes #Humor #Extravagante #Apocalipsis #Marvel

Salvador Dali, Boris Karloff y Frank Sinatra fueron los jueces que eligieron de entre 500.000 propuestas el dibujo de Basil Wolverton #BasilWolverton #Dibujantes #CienciaFicción #Grotesco #Futuro #Catástrofes #Humor #Extravagante #Apocalipsis #Marvel submitted by entrelineas_org to incredulos [link] [comments]


2021.11.28 11:45 petter12346 pitchfinance project will be a successful project

This project will be a successful project in the current time, as it has a qualified team who are focused on making this project successful.
https://pitchfinance.app/
submitted by petter12346 to cryptoieoinvestment [link] [comments]


2021.11.28 11:45 Upset_Tear Why does my board constantly turn right? Me and my dad have cleaned my bearing and there new trucks.

submitted by Upset_Tear to NewSkaters [link] [comments]


2021.11.28 11:45 Guyinthehall8 Visiting the Walmart Museum! Take a break from holiday shopping and relax with this quirky little stop!

Visiting the Walmart Museum! Take a break from holiday shopping and relax with this quirky little stop! submitted by Guyinthehall8 to Arkansas [link] [comments]


2021.11.28 11:45 I-D-H-A-N Rate my Gen 8 National Dex AG Team

Y (Unown-Y) @ Choice Specs
Ability: Levitate
EVs: 252 SpA / 4 SpD / 252 Spe
Modest Nature
IVs: 0 Atk
- Hidden Power [Fighting]

U (Unown-U) @ Choice Specs
Ability: Levitate
EVs: 252 SpA / 4 SpD / 252 Spe
Modest Nature
IVs: 0 Atk
- Hidden Power [Ghost]

R (Unown-R) @ Choice Specs
Ability: Levitate
EVs: 252 SpA / 4 SpD / 252 Spe
Modest Nature
IVs: 0 Atk
- Hidden Power [Grass]

G (Unown-G) @ Choice Specs
Ability: Levitate
EVs: 252 SpA / 4 SpD / 252 Spe
Modest Nature
IVs: 0 Atk
- Hidden Power [Ice]

A (Unown) @ Choice Specs
Ability: Levitate
EVs: 252 SpA / 4 SpD / 252 Spe
Modest Nature
IVs: 0 Atk
- Hidden Power [Psychic]

Y (Unown-Y) @ Choice Specs
Ability: Levitate
EVs: 252 SpA / 4 SpD / 252 Spe
Modest Nature
IVs: 0 Atk
- Hidden Power [Ground]
submitted by I-D-H-A-N to stunfisk [link] [comments]


2021.11.28 11:45 masterpig09 Stay hydrated kids!!!! [No spoilers]

Stay hydrated kids!!!! [No spoilers] submitted by masterpig09 to subnautica [link] [comments]


2021.11.28 11:45 FilipsSamvete Otterly adorable

Otterly adorable submitted by FilipsSamvete to antimeme [link] [comments]


2021.11.28 11:45 Buckeyestacker Penny Roll Hunt & Fill #9 Buckeye stacker Penny Hunt & Fill Series #buckeyestacker

Penny Roll Hunt & Fill #9 Buckeye stacker Penny Hunt & Fill Series #buckeyestacker submitted by Buckeyestacker to CRH [link] [comments]


2021.11.28 11:45 annyaonweb My rainbow dress & dragon kingdom artwork~ First reddit post!

My rainbow dress & dragon kingdom artwork~ First reddit post! submitted by annyaonweb to RainbowEverything [link] [comments]


http://hismileteeth.ru