mise API - v0.0.0
    Preparing search index...

    Interface IStorageProvider

    Storage-provider abstraction (IStorageProvider) and provider exports.

    Interface for storage providers. Defines the methods required for a storage provider to be compatible with cumin.

    interface IStorageProvider {
        basename(path: string): string;
        exists(path: string): Promise<boolean>;
        isDirectory(path: string): Promise<boolean>;
        join(...paths: string[]): string;
        mkdir(path: string, options?: { recursive?: boolean }): Promise<void>;
        read(path: string): Promise<string | null>;
        readBinary(path: string): Promise<ArrayBuffer | null>;
        readdir(path: string): Promise<string[]>;
        remove(path: string): Promise<void>;
        write(path: string, data: string): Promise<void>;
    }

    Implemented by

    Index
    • Parameters

      • path: string
      • Optionaloptions: { recursive?: boolean }

      Returns Promise<void>

    • Parameters

      • path: string

      Returns Promise<ArrayBuffer | null>

    • Parameters

      • path: string
      • data: string

      Returns Promise<void>