Public: anyone can read this; the crew can change it.

The forge-wide map leaves map.ts for src/web/pages/global-map.ts #6310

shipped production is serving it opened this has it
opened this

For: src/web/pages/map.ts is too big to read or to change without a conflict; globalLanes, laneHtml, globalMapPage, globalMapJson and the helpers only they use (map.ts:1667–end) is one concept and gets its own module, with no change in behaviour.

Done:

  • [ ] src/web/pages/global-map.ts holds globalLanes, laneHtml, globalMapPage, globalMapJson and the helpers only they use (map.ts:1667–end); src/web/pages/map.ts keeps none of it and imports or calls it from the new file.
  • [ ] Every route, page and form answers exactly as before: the forge-wide map page and its JSON answer byte for byte as before; the map tests pass unchanged; server.ts imports globalMapPage from the new file.
  • [ ] A helper both files need is exported from where it lives now; nothing is copied.
  • [ ] Before pushing: bun x tsc --noEmit, the tests that cover the moved code, and bun scripts/design-lint.ts when src/web/ changes. A red test elsewhere that main also has is named in the pull.

Files: src/web/pages/map.ts, src/web/pages/global-map.ts, the files that import what moved.

Risk: the repository map's drawing helpers (layout, drawMap, wordFor) stay in map.ts and are imported, not copied.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs