Effect Write-Behind Cache
Write coalescing with a journal so eventual durability is not data loss. Write-through pays the store on every keystroke (100 counter bumps, 100 store writes); naive write-behind buffers in memory and a crash between flushes silently drops every acknowledged write. This holds both ends: writes coalesce per key (100 bumps flush as one store write) but every accepted write is journaled first, and recovery replays the journal so a crash costs zero acknowledged writes. The demo proves 100x fewer writes than write-through and full recovery where the unjournaled buffer evaporates. Pinned to effect 4.0.0-beta.98.
npx shadcn@latest add @compronents/effect-write-behind-cacheInstalls from ui.aryank.space. Needs a registry token and a one-time @compronents entry in components.json. The docs walk through both.
Naive write-behind buffers writes in memory and flushes later. A crash between flushes drops every acknowledged write: the cache said OK, the store never heard.