Where in the World Am I?
The article discusses how to use web services in Mini Micro to determine your geographical location. It explains how to retrieve your public IP address and obtain location details using an API. Additionally, it provides a code example to visualize your location on a map.
- ▪The process begins by finding your external IP address using the api.ipify.org service.
- ▪Another service, ip-api.com, is used to get location information based on the IP address.
- ▪The article includes a code example that plots your location on a map using Mini Micro.
Opening excerpt (first ~120 words) tap to expand
try { if(localStorage) { let currentUser = localStorage.getItem('current_user'); if (currentUser) { currentUser = JSON.parse(currentUser); if (currentUser.id === 955389) { document.getElementById('article-show-container').classList.add('current-user-is-article-author'); } } } } catch (e) { console.error(e); } JoeStrout Posted on May 20 Where in the World Am I? #programming #miniscript #minimicro #geolocation There are so many fun things you can do with web services, and most of them are trivial to use in Mini Micro. Today, let's use a couple of these together to plot your location on a map of the world! Finding Your Place In the World ...begins by finding your external (or public) IP address.
…
Excerpt limited to ~120 words for fair-use compliance. The full article is at DEV.to (Top).