Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

Base64.decode

import { Base64 } from "https://raw.githubusercontent.com/i-xi-dev/base64.es/4.1.13/mod.ts"; 

const { decode } = Base64;

Decodes a Base64-encoded string into an Uint8Array.

@example
Base64.decode("AwIBAP/+/fw=");
// → Uint8Array[ 0x03, 0x02, 0x01, 0x00, 0xFF, 0xFE, 0xFD, 0xFC ]
@example
const rfc4648urlOptions = Base64.Options.RFC4648URL;
Base64.decode("AwIBAP_-_fw", rfc4648urlOptions);
// → Uint8Array[ 0x03, 0x02, 0x01, 0x00, 0xFF, 0xFE, 0xFD, 0xFC ]
function decode(encoded: string, options?: Options): Uint8Array;
§
decode(encoded: string, options?: Options): Uint8Array
[src]

§Parameters

§
encoded: string
[src]

The string to decode.

§
options?: Options optional
[src]

The Base64.Options dictionary.

§Return Type

§
Uint8Array
[src]

An Uint8Array containing the decoded byte sequence.