Urgent.News

What's breaking now, across thousands of outlets.

Tech

Building Software for Places Where the Internet Doesn't Work

Originally published at parvejshah.com/blog/offline-first-pwa-emergency-volunteer-networks by Parvej Shah . Blood donor matching is time-sensitive in a way most software problems aren't. When a patient needs a specific blood type during a critical procedure, the medical team is working with a narrow window. The volunteer coordinator needs to identify available donors, contact them, and arrange a…

Blood donation matching is a time-sensitive process where donors must be quickly identified and contacted for specific blood types during critical procedures. The volunteer coordinator at Badhan, a blood donation organization at the University of Dhaka, operates a networked donor management platform to streamline the process. However, hospital environments often have unreliable network connectivity due to thick concrete walls and dense infrastructure creating mobile dead zones.

An offline-capable application, which merely displays cached content when offline, would fail in this critical situation. Therefore, an offline-first approach, where local storage serves as the primary data source and network requests synchronize local data with the server, is necessary. The data synchronization architecture uses IndexedDB to store donor records and syncs any changes from the server when a network connection is available.

A Service Worker Caching Strategy, implemented with Workbox, pre-caches static assets and runtime caches API responses, allowing fresh data when the network is available and cached data when it's not. The offline-first approach not only ensures functionality in areas with unreliable connectivity but also improves speed by pre-computing eligibility flags for blood donation guidelines.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

More from Wednesday 26 August →