( Case study ) Mobile app · Offline-first

Daftar

Daftar is an offline-first credit ledger for corner shops in West Africa and the Arab world, replacing the paper notebook with live customer balances.

The problem

Corner shops sell on credit every day and track it in a paper notebook. Pages get lost, totals are added by hand, and asking a customer to pay is awkward. Many shops have weak or no internet, so a cloud app is not an option.

The approach

A pocket notebook that works fully offline: no account, no server. Two taps record credit given or a payment received, balances update live, and a polite WhatsApp reminder is one tap away, in the shop's own language.

What it does

  • Customers with live balances: who owes you and who has paid in advance
  • Two-tap entries for credit and payments (cash, Wave, Orange Money, MTN MoMo and more)
  • WhatsApp reminders with a polite pre-filled message
  • French, Arabic (right-to-left) and English, with 11 currencies including GNF, XOF and MAD
  • Optional PIN lock that relocks after 30 seconds in the background
  • CSV export and JSON backup and restore: the shop owns its data

Engineering decisions

Offline by design

All data lives in SQLite on the phone with versioned migrations. There is no backend, so the app works in a market with no signal.

Money as integers

Amounts are stored in integer minor units, never floats, so balances never drift by a rounding error.

Security without accounts

The PIN is hashed with expo-crypto and kept in the device secure store, not in the database.

Pure, tested domain logic

Currency, reminders, CSV and plan limits live in plain TypeScript modules with Jest tests, separate from the UI.

Stack

  • React Native
  • Expo Router
  • TypeScript
  • expo-sqlite
  • expo-secure-store
  • Jest

Status

Working app, open source on GitHub.