MCPcopy Create free account
hub / github.com/dfinity/orbit / readFileIntoUint8Array

Function readFileIntoUint8Array

cli/src/utils.ts:61–66  ·  view source on GitHub ↗
(filePath: string)

Source from the content-addressed store, hash-verified

59};
60
61export const readFileIntoUint8Array = async (filePath: string): Promise<Uint8Array> => {
62 const buffer = await readFile(filePath);
63 const uint8Array = new Uint8Array(buffer);
64
65 return uint8Array;
66};
67
68export const toBlobString = (buffer: Uint8Array): string => {
69 return Array.from(buffer)

Callers 1

getAppRegistryEntryFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected