* @returns {Uint8Array} Byte array representation of the input string\r
*/\r
toBytes (bin: string): Uint8Array {\r
- const bytes = []\r
+ const bytes: number[] = []\r
while (bin.length > 0) {\r
const bits = bin.substring(0, 8)\r
bytes.push(parseInt(bits, 2))\r
throw new TypeError('Invalid padding')\r
}\r
let integer = BigInt(decimal)\r
- const bytes = []\r
+ const bytes: number[] = []\r
while (integer > 0) {\r
const lsb = BigInt.asUintN(8, integer)\r
bytes.push(Number(lsb))\r