We spent a month taking the file apart. It got 556 lines longer.

Code entropy, measured, and the ratchet that stops it — extraction was working and the file still grew, because features kept arriving. That part is inevitable: entropy is whack-a-mole and you do not win it. What helped was a number allowed to move in one direction.

Every figure below is read out of a file that is in the tree — the caps and their history from eslint.config.mjs, the ratchet that was retired and the reason from scripts/guardrails.sh. Nothing here is estimated, and nothing is rounded to make a better point.

On 27 July, AppShell.tsx was 3,250 lines. On 27 August it was 3,806. In between, it was being taken apart on purpose: handlers moved into session hooks, flags moved into stores, whole domains left the file. The extraction was real and it was working. The file still grew by 556 lines.