import { Server } from "https://deno.land/x/socket_io@0.2.0/mod.ts";
Targets a room when emitting.
Examples
// the “foo” event will be broadcast to all connected clients in the “room-101” room
io.to("room-101").emit("foo", "bar");
// the “foo” event will be broadcast to all connected clients in the “room-101” room io.to("room-101").emit("foo", "bar");
// with an array of rooms (a client will be notified at most once) io.to(["room-101", "room-102"]).emit("foo", "bar");
// with multiple chained calls io.to("room-101").to("room-102").emit("foo", "bar");