Is it possible to read data as stream in websockets on workers ?

Hi, I have a worker acting as a websocket proxy. It's connecting correctly and messages are flowing through but I'm now build a piece inside of the proxy that reads pieces of the messages. The messages themselves can be large pieces of data so I'm wondering is it possible to consume the data as a stream. So far I'm only getting objects & strings when using the listener on the message event.
ws.addEventListener("message", async (msg) => {
// read parts of msg
});
ws.addEventListener("message", async (msg) => {
// read parts of msg
});
0 Replies
No replies yetBe the first to reply to this messageJoin