Calculates the SHA256 hash of the given value.
import { sha256 } from "thirdweb/utils";const hash = sha256("0x1234");
function sha256( value: `0x${string}` | Uint8Array, to?: TTo,): Sha256Hash<TTo>;
The value to hash. It can be either a hexadecimal string or a Uint8Array.
let value: `0x${string}` | Uint8Array;
(Optional) The desired output format of the hash. Defaults to 'hex'.
let to: TTo;
let returnType: Sha256Hash<TTo>;
The SHA256 hash of the value in the specified format.