base64-decode-utils

A (very) small library providing utility methods to decode base64 strings using Node Buffer API


Keywords
base64, decode, byte, int
License
MIT
Install
npm install base64-decode-utils@0.0.2

Documentation

Base64 decode utils

A small library providing utility methods to decode base64 strings using Node Buffer API.

Build Status Known Vulnerabilities https://david-dm.org/ceccode/base64-decode-utils.svg

Installation

npm install base64-decode-utils

 Usage

const base64DecodeUtils = require('base64-decode-utils');


const encoded = "SGVsbG8gV29ybGQh";
base64DecodeUtils.decodeToString(encoded); //Hello World!

API

  decodeToString(stream)
  decodeToHex(stream)
  decodeToUtf8FromHex(stream)
  decodeToIntFromByte(stream)
  decode(stream, 'string') //default decode byte stream to int

Test

npm test

Coverage

npm run-script test-travis

License

MIT license