Back to the Catalog
system-design
frontend

Offline & Local-First Design

12 questions

A local-first app treats the network as an enhancement, not a requirement. Work through service-worker caching strategies (cache-first, network-first, stale-while-revalidate), durable client storage, queueing and replaying mutations made while offline, and the genuinely hard part — resolving conflicts when two clients diverge (last-write-wins, version vectors, and CRDTs).

Questions

  1. Not answered. Which caching strategy serves the cached response instantly, then refreshes the cache in the background?
  2. Not answered. Which storage APIs can code inside a service worker use directly?
  3. Not answered. Why does this IndexedDB write throw TransactionInactiveError?
  4. Not answered. By default, is the data your app writes to IndexedDB safe from the browser deleting it?
  5. Not answered. What does an optimistic UI update commit you to handling?
  6. Not answered. What one-word term names the dedup key for replaying queued mutations?
  7. Not answered. Which API defers a failed request until the browser regains connectivity — even after the page has closed?
  8. Not answered. What is the fundamental risk of Last-Write-Wins conflict resolution?
  9. Not answered. What does a version vector (vector clock) actually give you?
  10. Not answered. Which statements about CRDTs are true?
  11. Not answered. After the two replicas merge, what value does the G-Counter report?
  12. Not answered. What does navigator.onLine === true actually guarantee?