Function toBufferBE

  • Convert a BigInt to a big-endian buffer.

    Parameters

    • num: bigint

      The BigInt to convert.

    • width: number

      The number of bytes that the resulting buffer should be.

    Returns Buffer

    A big-endian buffer representation of num.