Package Exports
- encdec
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (encdec) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
encdec
encdec is a node module that helps you baseXX encode and decode.
It defaults to using base58 encoding, but can easily be adapted for
base16, base32, base64 - or any other base - by passing the alphabet
you want to use to the create() method.
Usage
var base58 = require('encdec').create() // defaults to base58
base58.encode(1000);
base58.decode('if');
// base32 encoding
var base32 = require('encdec').create('ABCDEFGHIJKLMNOPQRSTUVWXYZ234567');
base32.encode(1000000);
base32.decode('6QSA');nodeunit
nodenunit is used for unit testing, and is included in this repo as a submodule to the node_modules folder. To download nodeunit after cloning this repository, enter the following at your command prompt:
git submodule init
git submodule updateTo run the tests, you'll need to install nodeunit if you haven't done so already.