Roman
Roman2w ago

Websocket implementation

Hey there, I’ve tried implementing Websockets into my project a few times, but I haven’t had any luck. Could someone please advise me on how to do it? https://gist.github.com/romanindermuehle/2b87cc36fd35a5e2827f7402a9c69dd7
Gist
Websocket
Websocket. GitHub Gist: instantly share code, notes, and snippets.
4 Replies
bartlomieju
bartlomieju2w ago
What is the problem you are facing?
Roman
RomanOP2w ago
In the chatroom.route.ts. I can’t upgrade to WebSocket.
bartlomieju
bartlomieju2w ago
It uses Hono, so I'd say it's most likely a bug in Hono's deno layer that prevent from doing the upgrade
Roman
RomanOP2w ago
So do you think my method for the WebSocket handler is correct? Because I never have done WebSocket before. And I’m also not sure if I use it correctly in the route. Because it shows an error but I can’t do much with it.

Did you find this page helpful?