RORK LABJP
TOOLING — Rork's developer repos keep moving: rork-xcode was updated on July 16, rork-device on July 15, and rork-plist on July 13OPUS46 — Claude Opus 4.6 is live in Rork, and Rork Max is built to assemble apps on top of Claude CodeSIM — A cloud iOS simulator runs in the browser, with one click to install on a device and two clicks to publish to the App StoreMAX — Rork Max emits pure Swift rather than React Native, reaching iPhone, iPad, Apple Watch, Apple TV, Vision Pro, and even iMessageNATIVE — That opens up HealthKit, ARKit and LiDAR, NFC, Dynamic Island, Live Activities, 3D through Metal, and on-device inference with Core MLSEED — Rork raised a $15M seed led by Left Lane Capital, with Peak XV and a16z Speedrun joining the roundTOOLING — Rork's developer repos keep moving: rork-xcode was updated on July 16, rork-device on July 15, and rork-plist on July 13OPUS46 — Claude Opus 4.6 is live in Rork, and Rork Max is built to assemble apps on top of Claude CodeSIM — A cloud iOS simulator runs in the browser, with one click to install on a device and two clicks to publish to the App StoreMAX — Rork Max emits pure Swift rather than React Native, reaching iPhone, iPad, Apple Watch, Apple TV, Vision Pro, and even iMessageNATIVE — That opens up HealthKit, ARKit and LiDAR, NFC, Dynamic Island, Live Activities, 3D through Metal, and on-device inference with Core MLSEED — Rork raised a $15M seed led by Left Lane Capital, with Peak XV and a16z Speedrun joining the round
Articles/Dev Tools
Dev Tools/2026-06-15Advanced

Designing Apps That Keep Working When the Signal Drops — Optimistic Updates and Resolving Conflicts on Reconnect

Make the Expo apps you build with Rork keep responding even when the signal drops in a subway or elevator. We assemble optimistic updates that move the screen first, and conflict resolution that reconciles when the connection returns, in working code.

Rork515Expo149Offline3State Management7Sync2

Premium Article

On the subway, I tried to check off a note in my own app, and the spinner would not stop. The signal had dropped. Because a one-tap action was built to wait for a network round trip, the app gave me nothing until we cleared the tunnel. From a user's point of view, that is indistinguishable from "broken."

What this drove home is that if you build the UI assuming connectivity, the app dies the moment connectivity is gone. Trains, elevators, basement shops — daily life is full of places where the signal cuts out. As an indie developer running several apps, low-rating reviews about behavior in these environments slowly chip away at your store stars.

Why a "wait first" design loses users

Many apps send an action to the server, wait for a success reply, and only then update the screen. The order feels natural, but it makes network slowness or loss translate directly into operation slowness. When an AdMob banner is loading in the background, the line is busier still and the wait stretches.

What the user wants is for the check to appear the instant they tap. The server's reply can honestly come later. So reverse the order: update the screen first, and let the send chase it afterward. That is the idea behind optimistic updates.

Update the screen first, push the send to the back

The skeleton of an optimistic update is simple. On tap, change local state immediately and, at the same time, enqueue "the operation that should go to the server." If the send succeeds, drop it from the queue; if it fails, keep it and retry later.

// optimisticStore.ts — change the screen first, enqueue the send
type Mutation = { id: string; type: "toggle"; itemId: string; value: boolean };
 
const pending: Mutation[] = [];
let items: Record<string, boolean> = {};
 
export function toggleItem(itemId: string, value: boolean, render: () => void) {
  // 1) update the screen first (perceived as instant)
  items[itemId] = value;
  render();
 
  // 2) enqueue the operation to send
  const mutation: Mutation = {
    id: `${itemId}-${Date.now()}`,
    type: "toggle",
    itemId,
    value,
  };
  pending.push(mutation);
  void flushQueue();
}

From the user's finger, the check appears in zero seconds. The network proceeds quietly underneath. The improvement in perceived speed is dramatic — in my app, the wait from action to feedback shrank from a measured ~400 milliseconds to nearly zero.

Thank you for reading this far.

Continue Reading

What follows includes implementation code, benchmarks, and practical content we hope you'll find useful. This site runs without ads — server and development costs are supported entirely by members like you. If it's been helpful, we'd be truly grateful for your support.

WHAT YOU'LL LEARN
Why operations freeze the instant the signal drops, and a design that makes perceived speed effectively zero with optimistic updates
Working conflict-resolution code that safely reconciles server and local divergence when the connection returns
How to persist the send queue so operations survive even if the app is killed
Secure payment via Stripe · Cancel anytime

Unlock This Article

Get full access to the rest of this article. Buy once, read anytime. This site is ad-free — your support goes directly toward keeping it running.

or
Unlock all articles with Membership →
Share

Thank You for Reading

Rork Lab is ad-free, supported entirely by members like you. We publish practical guides daily with implementation code, benchmarks, and production-ready patterns. If you've found it useful, we'd love to have you on board.

  • Copy-paste ready implementation code
  • New advanced guides published daily
  • $5/mo or $10 for lifetime access
View Membership →

Related Articles

Dev Tools2026-06-25
Why Paying Members See a Paywall in Airplane Mode — Keeping RevenueCat Entitlements Alive Offline
Open the app on a weak connection and a paying subscriber sees a paywall flash for a second. Here is how RevenueCat's customerInfo wavers on an offline launch, and a cache design that keeps entitlements valid with a trust window — written as working code for an Expo app.
Dev Tools2026-06-15
The Day a Third Reason to Hide Ads Appeared — Folding Rork App Ad-Free Logic Into One Place
Ads show only on one screen for paying users, or ads never show for free users. The usual cause is that the condition for hiding ads is scattered across the code. Here is how I fold three reasons — subscription, lifetime purchase, and a timed reward unlock — into a single state and route every ad through one hook, written as an implementation note from running six apps as an indie developer.
Dev Tools2026-07-17
Shipping Notifications Without Asking First — Provisional Authorization in Rork Apps, and the Expo Snippet That Quietly Undoes It
iOS lets you start delivering notifications with no permission dialog at all, via provisional authorization. The catch: expo-notifications reports granted as false for provisional devices, so the registration snippet in Expo's own docs re-requests permission and fires the very dialog you were avoiding. Here's why granted lies, a hook that models authorization as five states, how to write notifications for quiet delivery, when to ask for the upgrade, and how to keep provisional out of your CTR.
📚RECOMMENDED BOOKS
Build a Large Language Model (From Scratch)
Sebastian Raschka
LLM Dev
Prompt Engineering for LLMs
Berryman & Ziegler
Prompting
AI Engineering
Chip Huyen
AI Eng
* Contains affiliate links
See all →