Struggling to understand the getLocation function

Feels like I’ve hit a wall with the Weather App Project. Different resources explain different ways to go about pulling your geolocation, but I can’t get the solutions to be compatible across multiple browsers.

What resource did you guys use to understand the function?

I used the HTML5 geolocation API, which seems to work well enough for most browsers. MDN has a very good tutorial for it, and if you use with an API that uses latitude and longitude (say simpleweather.js or open weather map), it becomes easier. Hope this helps!

What have you tried? Can you post some code?