Skip to content

✨ feat: expose WebSocket instance for node adapter#166

Open
rphlmr wants to merge 5 commits into
mainfrom
feat/december-updates
Open

✨ feat: expose WebSocket instance for node adapter#166
rphlmr wants to merge 5 commits into
mainfrom
feat/december-updates

Conversation

@rphlmr
Copy link
Copy Markdown
Owner

@rphlmr rphlmr commented Dec 7, 2025

Fixes #164

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new Bot commented Dec 7, 2025

Open in StackBlitz

pnpm add https://pkg.pr.new/rphlmr/react-router-hono-server@166

commit: 7e69cc1

@@ -6,10 +7,18 @@ console.log("loading server");
// Store connected clients
const clients = new Set<WSContext>();
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of storing clients manually could use wss.clients in this example, since @hono/node-ws has clientTracking enabled.

@hilja
Copy link
Copy Markdown

hilja commented Mar 3, 2026

This has worked great so far 🫡 Might merging it? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Could you give us the wss instance in upgradeWebSocket?

2 participants