ownfiles
Version:
A library to manage files in a Solid User's Pod
19 lines • 1 kB
TypeScript
import FileClient from './fileClient';
import { Quad_Subject } from 'rdflib/lib/tf-types';
export interface CreateOptions {
name: string;
contents: any[] | Blob | string;
contentType: string;
headers?: Headers | Record<string, string>;
}
export declare type ExtendedResponseType = Response & {
responseText: string;
req?: Quad_Subject;
size: number;
error: string;
};
export declare const create: (this: FileClient, resourceAddress: string, options?: Partial<CreateOptions>) => Promise<Response>;
export declare const createFolder: (this: FileClient, folderAddress: string, options?: Partial<CreateOptions> | undefined) => Promise<ExtendedResponseType>;
export declare const createFile: (this: FileClient, fileAddress: string, options?: Partial<CreateOptions>) => Promise<Response>;
export declare const createIfNotExist: (this: FileClient, resourceAddress: string, options?: Partial<CreateOptions>) => Promise<Response | undefined>;
//# sourceMappingURL=create.d.ts.map