import type { FileMeta } from "../types.ts"; // export type FileEncoding = "utf8" | "arraybuffer" | "dataurl"; // export type FileData = ArrayBuffer | string; export interface SpacePrimitives { // Returns a list of file meta data as well as the timestamp of this snapshot fetchFileList(): Promise; readFile( name: string, ): Promise<{ data: Uint8Array; meta: FileMeta }>; getFileMeta(name: string): Promise; writeFile( name: string, data: Uint8Array, // Used to decide whether or not to emit change events selfUpdate?: boolean, meta?: FileMeta, ): Promise; deleteFile(name: string): Promise; }