( input: string | Uint8Array_, )
| 145 | * ``` |
| 146 | */ |
| 147 | export function decodeHex( |
| 148 | input: string | Uint8Array_, |
| 149 | ): Uint8Array_ { |
| 150 | if (typeof input === "string") { |
| 151 | input = new TextEncoder().encode(input) as Uint8Array_; |
| 152 | } |
| 153 | return input.subarray(0, decode(input, 0, 0, rAlphabet)); |
| 154 | } |