The production server was sending raw Yjs updates but the client (y-websocket's WebsocketProvider) expects the y-protocols sync protocol with message type headers. This caused "Unexpected end of array" errors on every connection. Rewrite to match the Vite dev plugin: use y-protocols/sync for document sync, y-protocols/awareness for presence, and lib0 for encoding. Verified locally: server starts, WebSocket connects, sync messages exchange correctly. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| brouter.test.ts | ||
| brouter.ts | ||
| db.ts | ||
| host-election.test.ts | ||
| host-election.ts | ||
| rate-limit.test.ts | ||
| rate-limit.ts | ||
| sessions.ts | ||
| use-routing.ts | ||
| use-yjs.ts | ||
| vite-yjs-plugin.ts | ||
| yjs-server.ts | ||