Skip to content

Case study · Offline retail POS and inventory app

MOPX

An offline point of sale and inventory app for small shops, live on Google Play. Built with React Native, Expo and SQLite on the phone, it began as my graduation project, MOB.

By · Updated

MOPX feature graphic with the tagline “Run your shop. Even offline.” next to a phone showing the sales dashboard

The problem

Small grocery shops, kiosks and popup stalls need billing and stock tracking, often with unreliable internet. MOPX runs the whole store on a phone (products, barcode lookup, billing, receipts and reports) with no server or account.

From graduation project to MOPX

MOB started in March 2025 as my graduation project. It stored products and bills as JSON arrays in AsyncStorage: fine for a student project, not for a point of sale.

In 2026 I rebuilt it in phases (stabilise the repository, move business data to SQLite, make billing correct, redesign the core POS flow), renamed it MOPX and published it on Google Play.

Data architecture

  • SQLite (expo-sqlite) is the main database, with idempotent migrations and repositories for products, categories, inventory, sales and settings.
  • Data from earlier installs moves from AsyncStorage into SQLite during migration; AsyncStorage now holds only preferences.
  • Each sale is one transaction (the sale, line items, payment, audit log entry and stock movements), so stock and sales cannot drift apart after a failure.
  • Business rules (cart totals, payment validation, receipts, reports, inventory checks) live in plain domain modules with their own unit tests, separate from the UI.

What it does

  • Barcode scanning with the camera, or manual code entry.
  • Inventory, with a reason recorded for every stock adjustment.
  • Billing with payment methods and the shop’s business profile on receipts.
  • PDF receipts and reports, JSON backup export and product CSV export.
  • A redesigned dashboard, billing, receipts, reports and settings, in light and dark themes.

Not built yet

MOPX is offline only for now. The repository lists what is not built yet: cloud sync, sign in, multiple users, local encryption and a screen for restoring backups.

Testing

Jest unit tests cover the domain logic (cart and scanner flows, barcodes, currency, receipts, backups) and the SQLite migrations and repositories. Lint and type checks run alongside.