base-convertor

1.1.0 • Public • Published

Base conversion

Convert data from any base to any base

API/usage


var convert = require('base-convertor');
//convert(data_string, input_chars, output_chars)

  //display 17 (base 10)
console.log(convert('10001', '01', '0123456789').toString()); 
  
  //display 10001 (binary format)

console.log(convert('17', '0123456789', '01').toString());

Credits

Keywords / shout box

base, conversion, bin2hex, hex2bin, bin2dec, hex2dec, dec2bin, dex2hex, dec2dec

Package Sidebar

Install

npm i base-convertor

Weekly Downloads

5

Version

1.1.0

License

ISC

Last publish

Collaborators

  • 131