bytesToNumber

Converts a Uint8Array of bytes to a number.

Example

import { bytesToNumber } from "thirdweb/utils";
const bytes = new Uint8Array([1, 164]);
const number = bytesToNumber(bytes);
console.log(number); // 420

Parameters

Returns

The converted number.