@devlander/utils
Version:
Comprehensive JavaScript and TypeScript utilities for seamless development. Includes object manipulation, data validation, and more.
9 lines (8 loc) • 302 B
TypeScript
/**
* Universal base64 encoder for Node.js, browser, and React Native
*
* Encodes a UTF-8 string to a base64-encoded string in any JS environment.
* @param str - The UTF-8 string to encode
* @returns The base64-encoded string
*/
export declare function encodeStringToBase64(str: string): string;