451-tools
Version:
Censorship resilient and distributed publishing: informed by the needs of publishers and their audiences, More Mirrors implements a set of offline fallback strategies for censorship resilient websites.
13 lines (12 loc) • 435 B
TypeScript
/**
* Converts a Base64 string to a Uint8Array.
* @param {string} base64 - The Base64 encoded string.
* @returns {Uint8Array} The decoded Uint8Array.
*/
export function base64ToUint8Array(base64: string): Uint8Array;
/**
* Converts a hexadecimal string to a Uint8Array.
* @param {string} hex - The hexadecimal string.
* @returns {Uint8Array} The decoded Uint8Array.
*/
export function hexToUint8Array(hex: string): Uint8Array;