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

std/encoding/binary.ts>varnum

Deno standard library
Go to Latest
The Standard Library has been moved to JSR. See the blog post for details.
function varnum
import { varnum } from "https://deno.land/std@0.42.0/encoding/binary.ts";

Decode a number from b, and return it as a number. Data-type defaults to int32. Returns null if b is too short for the data-type given in o.

Parameters

b: Uint8Array
optional
o: VarnumOptions = [UNSUPPORTED]

Returns

number | null