Package Exports
- hada
- hada/lib/index.js
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 (hada) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
hada
helpers for converting between bytes, strings, numbers, and more
import * as hada from 'hada'
hada.bytesToInt([255, 255]) // 65535
hada.intToBytes(65535) // [255, 255]
hada.hexToBytes('ffff') // [255, 255]
hada.bytesToHex([255, 255]) // 'ffff'
hada.stringToAsciiHex('hello world') // '68656c6c6f20776f726c64'
hada.asciiHexToString('68656c6c6f20776f726c64') // 'hello world'
hada.stringToAsciiBytes('hello world')
//[104, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100]
hada.asciiBytesToString([104, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100])
// 'hello world'