ethereumjs-monorepo

@ethereumjs/util


@ethereumjs/util / equalsBytes

Function: equalsBytes()

equalsBytes(a, b): boolean

Defined in: packages/util/src/bytes.ts:547

Parameters

a

Uint8Array

The first Uint8Array to compare.

b

Uint8Array

The second Uint8Array to compare.

Returns

boolean

True if the Uint8Arrays are equal, false otherwise.

Notice

Compares two Uint8Arrays and returns true if they are equal. Implementation copied from ethereum-cryptography https://github.com/ethereum/js-ethereum-cryptography/blob/main/src/utils.ts#L35-L45