Function hashTransactionUiOrder

  • Compute a transaction hash (A.K.A. "transaction ID" or "TXID") from an encoded transaction in user interface byte order. This is the byte order typically used by block explorers, wallets, and other user interfaces.

    To return this result as a string, use hashTransaction.

    Returns

    the transaction hash in User Interface byte order

    Parameters

    • transaction: Uint8Array

      the encoded transaction

    • sha256: {
          hash: ((input: Uint8Array) => Uint8Array);
      } = internalSha256

      an implementation of sha256

      • hash: ((input: Uint8Array) => Uint8Array)
          • (input: Uint8Array): Uint8Array
          • Returns the sha256 hash of the provided input.

            To incrementally construct a sha256 hash (e.g. for streaming), use init, update, and final.

            Parameters

            • input: Uint8Array

              a Uint8Array to be hashed using sha256

            Returns Uint8Array

    Returns Uint8Array

Generated using TypeDoc