Open
Description
I ran out of time to implement this, but if anyone's interested in contributing, take a look at how it's done in the hattip-ws/node
adapter. The difficulty is that UWS (like Node) doesn't handle upgrade requests in a normal request handler, instead opting for a special, out-of-line handler. Also, unlike with Deno/Bun/Cloudflare, crossws
wraps the UWS/Node request in a "proxy" object (presumedly for normalization), so the call to forwardHattipContext
is less straight-forward.
Here's the hattip-ws/node
implementation:
hattip-ws/src/adapters/node/node.ts
Lines 41 to 78 in ef25ef7