A pause with two sides: the hook contract and the worker protocol

Suppose you’re writing a Turing-machine interpreter that runs in a Web Worker. The UI needs to show a trace — how the machine steps from…