Monorepo for Aesthetic.Computer aesthetic.computer
4
fork

Configure Feed

Select the types of activity you want to include in your feed.

aa: auto-reload on new deploy so in-piece edits land live

Poll /api/version after boot and trigger window:reload when the deployed
build changes. Same pattern as dumduel. Lets @jeffrey edit aa.mjs through
aa itself and see the changes without a manual refresh.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

+18
+18
system/public/aesthetic.computer/disks/aa.mjs
··· 76 76 setStatus("loading"); 77 77 userHandleRef = handle; 78 78 79 + // Version polling — auto-reload on new deploy so edits to aa.mjs made 80 + // from within aa itself come back live without a manual refresh. 81 + (async () => { 82 + try { 83 + const res = await fetch("/api/version"); 84 + if (!res.ok) return; 85 + const current = (await res.json()).deployed; 86 + while (true) { 87 + try { 88 + const r = await fetch(`/api/version?current=${current}`); 89 + if (!r.ok) break; 90 + const data = await r.json(); 91 + if (data.changed !== false) { send?.({ type: "window:reload" }); break; } 92 + } catch { break; } 93 + } 94 + } catch {} 95 + })(); 96 + 79 97 if (!user?.sub) { 80 98 setStatus("unauth"); 81 99 pushSystem("log in first to talk to aa.");