JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1000
  • Score
    100M100P100Q112370F
  • License ISC

Package Exports

  • buffer-to-base64
  • buffer-to-base64/package.json

Readme

buffer-to-base64

A base64 encoder/decoder with gzip or deflate abilities.

import { encode, decode } from 'buffer-to-base64';

// return a base64 string after compression
const packed = encode(buffer);

// return an ArrayBuffer after decompression
const original = decode(packed);

This module goal is to simplify the embedding of WASM or other blobs within code as base64 that can return the original array without bloating space on the file.