WeSearch

I built Norway's EV charging map with Next.js and MapLibre GL JS — and hit a race condition that took me three sessions to fix

·8 min read · 0 reactions · 0 comments · 22 views
#ev#maps#webdev
I built Norway's EV charging map with Next.js and MapLibre GL JS — and hit a race condition that took me three sessions to fix
TL;DR · WeSearch summary

Ayyad Anwar developed an interactive EV charging map for Norway using Next.js and MapLibre GL JS. The project features over 10,000 charging stations and employs a greedy algorithm for optimal route planning. Anwar encountered and resolved a race condition during development that delayed the display of route lines on the map.

Key facts
Original article
DEV.to (Top)
Read full at DEV.to (Top) →
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 === 3942169) { document.getElementById('article-show-container').classList.add('current-user-is-article-author'); } } } } catch (e) { console.error(e); } Ayyad Anwar Posted on May 20 I built Norway's EV charging map with Next.js and MapLibre GL JS — and hit a race condition that took me three sessions to fix #nextjs #typescript #webdev #maps I recently shipped StrømVei — an interactive EV charging map and route planner for Norway, built with Next.js 16, TypeScript, MapLibre GL JS, and the free Nobil API.

Excerpt limited to ~120 words for fair-use compliance. The full article is at DEV.to (Top).

Anonymous · no account needed
Share 𝕏 Facebook Reddit LinkedIn Threads WhatsApp Bluesky Mastodon Email

Discussion

0 comments

More from DEV.to (Top)