method WebSocketService.prototype.room
WebSocketService.prototype.room(name: string): WebSocketRoom

Returns the named room, creating it on first use.

Creating is the point: the first call for a name registers a room. Use IWebSocketService.peek to read a caller-supplied name without registering anything.

Parameters

name: string

Room name

Return Type

The room

Usage

import { WebSocketService } from "websocket-plugin/src/index.ts";