UNPKG

histoire

Version:

A fast story book powered by Vite

25 lines • 1.34 kB
import type { Context } from '../context.js'; import type { ExecutionService } from '../runtime/execution-service.js'; import type { CreateServerOptions as ViteServerOptions } from './vite-servers.js'; /** Dev generation startup and publication ownership. */ export interface CreateServerOptions extends ViteServerOptions { /** Headless consumers can omit agent/comment service acquisition. */ agents?: boolean; /** Cancels startup when its owning controller closes or restarts. */ signal?: AbortSignal; /** Suppresses publication from a superseded runtime generation. */ isActive?: () => boolean; /** Controller-owned shared lane for UI fallback tests and MCP operations. */ execution?: ExecutionService; } /** Starts both Vite servers and owns their watchers, collection and plugin hooks. */ export declare function createServer(ctx: Context, options?: CreateServerOptions): Promise<{ server: import("vite").ViteDevServer; viteConfigFile: string; ready: Promise<void>; collect: () => Promise<void>; onCollection: (handler: (event: import("./collect.js").CollectionEvent) => void | Promise<void>) => () => void; readonly collectionOutcomes: Map<string, import("../collect/outcome.js").StoryCollectionOutcome>; close: () => Promise<void>; }>; //# sourceMappingURL=index.d.ts.map