(str: string)
| 35 | } |
| 36 | |
| 37 | export function stringToU8Array(str: string): Uint8Array { |
| 38 | return new Uint8Array(str.split('').map((c) => c.charCodeAt(0))) |
| 39 | } |
| 40 | |
| 41 | export function u8ToString(u8: Uint8Array): string { |
| 42 | return String.fromCharCode.apply(null, u8 as unknown as number[]) |
no outgoing calls
no test coverage detected