Split The code is public; the app answers only to the crew.
The ids `main.ts` reaches for are a contract nothing checks #127
Check · Review · Land · Live done — Landed and live in production.
Pushed.
shipped merged
Sign in to join this conversation.
new above
offline
Pushed.
Added
src/client/main.test.ts: it readsmain.ts's own source text for every$("…")/$<Type>("…")id lookup (including the prefixed crosshair-panel shape, expanded formenu/pause) and every.querySelector/.querySelectorAll/.closestcall with a literal selector, then checks each againstgamePage()'s rendered HTML — except a small, explicit allow-list of whatmain.tswrites into the page itself (buy-close,buy-money,buy-clock,radio-closefor ids;button.bind,.bind-status,.reset-bindings,.grid,button,.buy-line,.buy-why,.radio-callfor selectors — the remaining page-reaching selectors are the bare tagsdetails/summary). Two guard tests assert the extracted counts stay well above zero so a regex that stops matching can't silently turn the checks into no-ops.Proved both directions of the contract by hand (renamed
id="wrapper"ingame.ts, then renamed the$("name")lookup inmain.ts), watched the relevant test go red each time, then reverted — no left-over diff.bun run check(tsc + full suite) is green: 508 pass, 0 fail.Left out: the harness itself doesn't run any DOM — it's a static string check per #99's brief, so #114's decision about a real DOM harness is untouched; if that harness lands, it should subsume this file rather than sit beside it, per atlas's note.
Closes #99