MCPcopy Index your code
hub / github.com/NoteProtocol/NoteWallet / stringToBytes

Function stringToBytes

src/utils.ts:73–77  ·  view source on GitHub ↗
(str: string)

Source from the content-addressed store, hash-verified

71}
72
73export function stringToBytes(str: string) {
74 const encoder = new TextEncoder();
75 const uint8array = encoder.encode(str);
76 return getValidatedHexString(Buffer.from(uint8array).toString("hex"));
77}
78
79export async function sleep(ms: number) {
80 return new Promise<void>((resolve) => setTimeout(resolve, ms));

Callers 2

pow-token.tsFile · 0.90
mintMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected