import type { KsAppClientData } from '@knapsack/types'; import type { MissingFileVerbosityOption } from './misc'; /** * There are two main flows in the CLI: * * Deploying: * 1. `knapsack build` * - `init` * - `build` * 2. `knapsack serve` * - `hydrate` * * Running locally: * 1. `knapsack start` * - `init` */ export interface CliLifecycle | undefined = undefined> { /** Ran after constructor & before `build` method during `build` & `start` commands */ init?: (opt: { missingFileVerbosity: MissingFileVerbosityOption; }) => Promise; /** Ran after constructor during `serve` command */ hydrate?(opt: HydrateData extends undefined ? { appClientData: KsAppClientData; } : { appClientData: KsAppClientData; hydrateData: HydrateData; }): Promise; /** * Ran after `init` during `build` command */ build?: () => Promise; writeHydrateData?: (data: Record) => Promise; readHydrateData?: () => Promise : HydrateData>; } //# sourceMappingURL=cli-lifecycle.d.ts.map