Function hexToBytes

  • Converts a hex string to the equivalent bytes

    Parameters

    • hex: string

    Returns Uint8Array

    Example

    hexToBytes('deadbeef') // Uint8Array(4) [ 222, 173, 190, 239 ]
    hexToBytes('0xdeadbeef') // Uint8Array(4) [ 222, 173, 190, 239 ]

Generated using TypeDoc