Skip to main content
The Deno 2 Release Candidate is here
Learn more
Latest
function decode
import { decode } from "https://deno.land/x/denjucks@1.1.1/src/deps/path/std/encoding/hex.ts";

Decode decodes src into decodedLen(src.length) bytes returning the actual number of bytes written to dst. Decode expects that src contains only hexadecimal characters and that src has even length. If the input is malformed, Decode returns the number of bytes decoded before the error.

Parameters

dst: Uint8Array
src: Uint8Array

Returns

[number, Error | void]