import { FileCollection, VizId } from "@vizhub/viz-types"; import { BuildResult } from "../build/types"; export type VizHubRuntime = { run: (options: { files: FileCollection; enableHotReloading?: boolean; enableSourcemap?: boolean; vizId?: VizId; clearConsole?: boolean; }) => void; cleanup: () => void; invalidateVizCache: (changedVizIds: Array) => Promise; }; export type BuildWorkerMessage = { type: "buildRequest"; files: FileCollection; enableSourcemap: boolean; requestId: string; vizId?: VizId; } | { type: "buildResponse"; requestId: string; buildResult?: BuildResult; error?: string; } | { type: "contentRequest"; vizId: string; requestId: string; } | { type: "contentResponse"; vizId: string; content: any; requestId: string; } | { type: "resolveSlugRequest"; slugKey: string; requestId: string; } | { type: "resolveSlugResponse"; vizId: VizId | null; requestId: string; } | { type: "invalidateVizCacheRequest"; changedVizIds: Array; requestId: string; } | { type: "invalidateVizCacheResponse"; requestId: string; }; export type WindowMessage = { type: "runJS"; js: string; } | { type: "runCSS"; css: string; } | { type: "runDone"; requestId: string; } | { type: "runError"; error: Error; requestId: string; } | { type: "runtimeError"; formattedErrorMessage: string; } | { type: "writeFile"; fileName: string; content: string; }; //# sourceMappingURL=types.d.ts.map