(store: Store)
| 20 | } |
| 21 | |
| 22 | function handleOpen(store: Store) { |
| 23 | // TODO: Add a way to subscribe to multiple resources in one request |
| 24 | for (const subject of store.subscribers.keys()) { |
| 25 | store.subscribeWebSocket(subject); |
| 26 | } |
| 27 | } |
| 28 | |
| 29 | function handleMessage(ev: MessageEvent, store: Store) { |
| 30 | if (ev.data.startsWith('COMMIT ')) { |
no test coverage detected