number-bin

Convert an integer number to a binary string.


Keywords
number, bin, binary, string, node
License
MIT
Install
npm install number-bin@0.0.4

Documentation

number-bin

NPM

Convert an integer number to a binary string.

var bin = require('number-bin');

bin(10);    // '1010'
bin(100);   // '1100100'
bin(1000);  // '1111101000'
bin(10000); // '10011100010000'