Cache the weather forecast for offline fallback
Radar flyout now also shows a 3-day Open-Meteo forecast (free, no API key) for the map's current center. Radar frames and the forecast fetch independently — one being unreachable doesn't hide the other. The last successful forecast is cached in localStorage and shown (with a "cached from" note) when the live fetch fails, so there's still something useful once actually offline. Radar tile images themselves aren't cached — that needs a Service Worker, left as a separate follow-up (see TODO.adoc).
This commit is contained in:
1 parent
707e71caf1
commit
8d090b0774
3 files changed
+173
-18
No files matched your search
@@ -15,7 +15,8 @@ independence from connectivity.
|
||||
* [ ] Overpass/OSM scripts to extract POIs (drinking water, dump stations, LPG, public toilets, laundromats, shops, springs)
|
||||
* [ ] Import Park4Night / iOverlander / Freecampsites data
|
||||
* [ ] Kiwix/ZIM offline Wikipedia linked to POI GPS coordinates
|
||||
* [ ] Cache weather and precipitation radar when temporarily connected (4G/5G/Wi-Fi)
|
||||
* [x] Cache weather forecast when temporarily connected — Open-Meteo 3-day forecast in the Radar flyout, last successful fetch cached in localStorage as a fallback when offline
|
||||
** [ ] Cache the radar tile *images* too, not just the forecast text — needs a Service Worker (own bigger task: registration, cache strategy, invalidation); app has HTTPS everywhere (reverse proxy, incl. the in-van local server) so it's viable, just not done yet
|
||||
|
||||
== NPS visual style
|
||||
|
||||
|
||||
Reference in new issue
Block a user