
Field agents in remote areas collect data with a fully offline PWA. Managers build forms and track submissions on a web dashboard. Sync happens automatically when agents return to network coverage. No more paper forms that take weeks to arrive.
A look inside how the app is built: the decisions, trade-offs, and engineering that makes it work.
Not offline mode bolted on later. The entire system assumes no internet. Connectivity is a bonus, not a requirement.
All features work without internet. Server down for a week? Field agents keep working.
4 core patterns: Offline-First, Sync Engine (FIFO), Outbox (guaranteed delivery), Strategic Caching.
Dexie.js IndexedDB + service worker cache. After first visit, app loads instantly with zero network requests.
Every submission queued locally first. FIFO processing. Mid-stream resume. Idempotent delivery prevents duplicates.
All submissions go to an IndexedDB Outbox first. Sync engine processes FIFO with ULID tracking.
Resumable sync at the media level — if photo 4/6 fails, only retries photo 4. Never re-syncs confirmed data.
Last-Writer-Wins with MERGE strategy for arrays. Every conflict logged with before/after state and device ID.
Admins build forms with drag-and-drop. Field agents collect with PWA. Same JSON powers both.
One JSON schema powers both platforms: drag-drop form builder on admin, mobile-first PWA in the field.
Form updates propagate on next sync. No app store review, no backend deploy. 2-second updates vs 2 weeks.
Admin map with color-coded sync markers showing agent name, form type, and sync status in real time.
Three caching strategies. Proactive storage management. WAL-mode crash recovery. Designed for $50 phones with 2GB storage.
3 strategies: Cache First (shell), Network First (forms), Stale-While-Revalidate (reference data).
Storage monitor checks every 5min. Auto-cleans synced data at 50-60% quota. Never deletes unsaved submissions.
WAL-mode IndexedDB recovers data on crash. Without WAL, power loss corrupts the database. Storage check before every write.
No more paper forms that take weeks to arrive. Agents open the app and start collecting. Managers see submissions as syncs come in.
Everything works without internet. Forms, GPS, camera, signatures all offline. Server goes down? Keep working like nothing happened.
Every submission saves locally first. Server confirms receipt before marking synced. Battery dies mid-save? Recovers on next boot.
Collect 50 forms offline, walk to town. Network drops after 37? Sync resumes from 38. Never starts over.
Drag and drop builder with 20+ field types. Same form works on dashboard and field app. No coding needed.
GPS polls every 1s when moving, 60s when still. Saves battery on long shifts. Photos compress before saving. All offline.
Three caching strategies. App code loads from cache instantly. Form definitions fall back to cache when offline. Reference data refreshes in background.
Monitors storage and cleans old data automatically. Unsaved submissions are never deleted. Alerts you when space is low.