export type FileContent = string | Uint8Array; export type GetFileContentFn = (filepath: string) => Promise | FileContent; export interface IPreviewControllerOptions { baseUrl: string; getFileContent: GetFileContentFn; indexFiles?: string[]; } export declare function normalizeFilepath(filepath: string): string; export declare function joinFilepath(filepath: string, addition: string): string; export declare function getExtension(filepath: string): string; export declare class PreviewController { private baseUrl; private indexFiles; private getFileContent; private initPromise; constructor(options: IPreviewControllerOptions); private getIndexAtPath; private handleWorkerRequest; private getRelayUrl; private _initPreview; /** * Initialize a preview and return the url at which the preview is being served **/ initPreview(): Promise; destroy(): void; }