UNPKG

@lueur/avatar

Version:

A TypeScript package to generate customizable SVG user avatars.

13 lines (12 loc) 440 B
"use strict"; // polyfill.ts Object.defineProperty(exports, "__esModule", { value: true }); // Only polyfill in Node.js (not browsers) if (typeof window === 'undefined') { if (typeof global.btoa === 'undefined') { global.btoa = (data) => Buffer.from(data, 'utf-8').toString('base64'); } if (typeof global.atob === 'undefined') { global.atob = (base64) => Buffer.from(base64, 'base64').toString('utf-8'); } }