feat(website): the event feed both ways, and Linked products

Publish my events: the Website's simple events as crosscode.event/1
(GET /api/feed/v1/events, updatedSince, removals in deleted for 90
days) and a signed event.changed to linked siblings. Show events
from: each sibling's feed every 15 minutes and at once on its signed
event.changed; read-only copies of only that sibling's events, one
bad event skipped, the last good copy kept. Admin: Linked products.
church.changed from Accounts refreshes the profile at once. Plan:
the video hero, more blocks and more pages move to website@1.1.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-25 14:37:42 +02:00
co-authored by Claude Opus 5.5
parent 193a338ed2
commit b767b45e64
16 changed files with 632 additions and 17 deletions
+3
View File
@@ -12,6 +12,7 @@ import { createCtx } from './context.js';
import { connectFromEnv, heartbeat, startHeartbeats } from './hub/client.js';
import { loadConfig } from './lib/config.js';
import { startYoutubeSync } from './site/youtube.js';
import { startFeedSync } from './feed/feed.js';
async function main() {
const config = loadConfig();
@@ -23,6 +24,7 @@ async function main() {
const server = app.listen(config.port, () => console.log(`[website] Listening on ${config.port} (${config.publicUrl}).`));
const stopHeartbeats = startHeartbeats(ctx);
const stopYoutube = startYoutubeSync(ctx);
const stopFeed = startFeedSync(ctx);
connectFromEnv(ctx).then((r) => {
if (r.connected || r.reason === 'already') heartbeat(ctx).catch(() => {});
@@ -31,6 +33,7 @@ async function main() {
const stop = async () => {
stopHeartbeats();
stopYoutube();
stopFeed();
server.close();
await db.$disconnect();
process.exit(0);