Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/tellojs/src/deps.ts>dgram.Socket#unref

The easy to use tello library written in typescript to control your drones!
Latest
method dgram.Socket.prototype.unref
import { dgram } from "https://deno.land/x/tellojs@v1.2.2/src/deps.ts";
const { Socket } = dgram;

By default, binding a socket will cause it to block the Node.js process from exiting as long as the socket is open. The socket.unref() method can be used to exclude the socket from the reference counting that keeps the Node.js process active, allowing the process to exit even if the socket is still listening.

Calling socket.unref() multiple times will have no addition effect.

The socket.unref() method returns a reference to the socket so calls can be chained.