0.1.4 • Published 8 years ago

base91-prebuilt v0.1.4

Weekly downloads
2
License
-
Repository
github
Last release
8 years ago

Description

base91.js is a base91 implementation in javascript that allows encoding/decoding of data to/from an ASCII representation that is more compact than base64.

More information about the base91 algorithm itself can be found here.

Requirements

Installation

npm install base91

Example

var base91 = require('base91');

console.log(base91.encode('node.js rules!'));
console.log(base91.decode(base91.encode('node.js rules!')).toString());

// outputs:
// lref5gTT$FQ;C90ohA
// node.js rules!

API

Functions

  • encode(< mixed >data) - string - Encodes data and returns the resulting base91 representation. data can be a string or an Array-like object (e.g. Buffer in node.js, Uint8Array or Array in browsers).

  • decode(< string >encodedData) - mixed - Decodes encodedData and returns the result. For node.js, it will return a Buffer, otherwise it will return a Uint8Array if available, or a plain Array as a final fallback.

0.1.4

8 years ago

0.1.3

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago

0.0.5

8 years ago