Skip to content

core: implement offline-first with queue and sync #12

@EmeditWeb

Description

@EmeditWeb

Problem

The app requires constant internet connectivity. In
emerging markets where StepFi targets learners,
internet connections are unreliable.

What To Build

  1. offline-queue.ts for action queuing
  2. offline-sync.ts for queue processing
  3. Connectivity hook with NetInfo
  4. Cache strategy with AsyncStorage TTL

Files To Touch

  • src/offline/ (new module)
  • hooks/useConnectivity.ts (new)
  • services/api.ts
  • app/_layout.tsx

Acceptance Criteria

  • App loads cached data when offline
  • Repayment queued when offline
  • Queue processes when back online
  • No crashes when network unavailable
  • npx expo export --platform web passes

Mandatory Checks Before PR

  • npx expo export --platform web passes
  • Tested with airplane mode enabled
  • PR references this issue

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions