Why apps like Linear never show a spinner, and how to build the engine behind it: a local store every read comes from, optimistic transactions, a server that orders every change, deltas and catch-up, an offline outbox with safe retries, field-level conflicts, fractional ordering, and a live two-client demo you can break.
Open Linear, change an issue's status, and the change is just there. No spinner, no "Saving...", no flash of the old value. Close your laptop on a train, keep working, and everything you did shows up for your teammates when you're back online. It feels faster than most desktop apps, and it's a web app.
That isn't a faster server. It's a different architecture.
Most web apps are request/response. The server owns the data; the browser asks for it and waits:
PATCH /issues/42 and shows a spinner.Every interaction pays a network round trip, and every screen needs loading, error and retry states.
Local-first apps flip this around. The browser keeps its own copy of the data, and the UI reads and writes only that copy:
The network still exists, but it's no longer between you and the UI.
Why this matters for perceived speed: reading from memory takes well under a microsecond. A network round trip takes 50–300 ms on a good connection, and much more on a bad one. Around 100 ms is where an interaction stops feeling instant, so request/response apps are always near or past that line, and local-first apps are nowhere near it.
What Linear's team has described publicly follows this shape. Sources worth your time:
In short:
In this tutorial you'll build that engine, piece by piece, as tested JavaScript: the local store, optimistic transactions and rollbacks, the server's ordering, deltas and catch-up, an offline outbox with safe retries, conflict handling and list ordering. Then you'll run all of it in a live demo with two "laptops", a latency switch and an offline toggle.
It's not free. You're building a small distributed system: you'll have to think about conflicts, permissions, schema changes and how much data fits in a browser. The last step covers those, and when not to go local-first.