API reference / @chanx-js/server / node / attachChanx
Function: attachChanx()
ts
function attachChanx(
server,
chanx,
__namedParameters?
): Attachment;Defined in: packages/server/src/adapters/node.ts:34
Serve chanx on a Node HTTP server: plain http, or the one Express, Fastify, Koa or NestJS (app.getHttpServer()) runs on. Upgrades for other paths go to the server's other WebSocket servers; those attached before chanx never see chanx's paths.
Parameters
| Parameter | Type |
|---|---|
server | Server |
chanx | Chanx |
__namedParameters | SocketOptions |