tobito
Version:
A package that returns bit representation of simple strings and numbers.
36 lines (26 loc) • 625 B
Markdown
Usage
```
// CLI
npm install tobito
// yourFile.js
const tobito = require('tobito)
let yourBinary = tobito('Some random text.')
console.log(yourBinary)
--v
[
'1010011', '1101111',
'1101101', '1100101',
'100000', '1110010',
'1100001', '1101110',
'1100100', '1101111',
'1101101', '100000',
'1110100', '1100101',
'1111000', '1110100',
'101110'
]
yourBinary = tobito(125)
console.log(yourBinary)
--> 1111101
```
Converts strings and numbers to their binary equivalent. Custom types return -1.
I don't know how useful this is except to show an example of the language computers speak.