import Converter from '../src/index';
const binToDec = new Converter(2, 10);
console.log(binToDec.convert('1111')); // '15'
import Converter from '../src/index';
const binToHex = new Converter('binary', 'hexadecimal');
console.log(binToHex.convert('1111')); // 'F'
import Converter from '../src/index';
const binToOctal = new Converter('bin', 8);
console.log(binToOctal.convert('1111')); // '17'
import Converter from '../src/index';
const binToHexatri = new Converter(2, 'hexatrige');
console.log(binToHexatri.convert('100011')); // 'Z'
import Converter from '../src/index';
const decToHex = new Converter(10, 16);
console.log(decToHex.convert('10')); // 'A'
import Converter from '../src/index';
const octalToDec = new Converter('octal', 'decimal');
console.log(octalToDec.convert('10')); // '8'
npm run test
👤 Lucas Guilherme
- Github: @Luc4sguilherme
Copyright © 2021 Lucas Guilherme.
This project is MIT licensed.