Module

std/node/net.ts>Socket#ref

Deno standard library
Go to Latest
method Socket.prototype.ref
import { Socket } from "https://dotland.deno.dev/std@0.116.0/node/net.ts";

Opposite of unref(), calling ref() on a previously unrefed socket will_not_ let the program exit if it's the only socket left (the default behavior). If the socket is refed calling ref again will have no effect.

Returns

this

The socket itself.