Skip to content
../projects

Malaria Surveillance System

Offline-first PWA for malaria case surveillance across Ethiopia’s health system — 6-level RBAC, geographic data scoping, and automatic sync for rural facilities.

React 18TypeScriptViteExpress.jsPostgreSQLSQLitePWAIndexedDBDockerVitest

// overview

A full-stack Progressive Web Application for malaria line-list data collection, surveillance, analytics, and reporting across Ethiopia’s administrative hierarchy (Region → Zone → Woreda → Facility), digitizing paper-based reporting for 7+ health facilities. The frontend (React 18, TypeScript, Vite) uses Zustand for state, Tailwind + shadcn/ui for the interface, Recharts for 8 interactive dashboard charts, and Dexie (IndexedDB) with a Service Worker for full offline entry that syncs automatically on reconnect. The Express.js backend implements JWT auth with bcrypt, a 6-level RBAC hierarchy with geographic data scoping enforced at the SQL layer, a dual-dialect abstraction supporting both SQLite (dev) and PostgreSQL (prod), 3-tier rate limiting, and complete audit logging. Solved key engineering challenges including offline conflict resolution via client-side UUIDs with last-write-wins semantics, per-user API cache isolation using JWT hashes to prevent cross-user data leakage on shared devices, and dialect-aware SQL for placeholder and date-function differences. Includes 5 automated report types with Excel export via SheetJS, data quality monitoring, death-case alerts, and 61 unit tests covering auth, RBAC, and validation, with full Docker/PM2/Nginx deployment documentation.

Malaria Surveillance System screenshot