UNPKG

nuxt

Version:

Nuxt is a free and open-source framework with an intuitive and extendable way to create type-safe, performant and production-grade full-stack web applications and websites with Vue.js.

17 lines (16 loc) 572 B
interface Preview { enabled: boolean; state: Record<any, unknown>; _initialized?: boolean; } interface PreviewModeOptions<S> { shouldEnable?: (state: Preview['state']) => boolean; getState?: (state: Preview['state']) => S; } type EnteredState = Record<any, unknown> | null | undefined | void; /** @since 3.11.0 */ export declare function usePreviewMode<S extends EnteredState>(options?: PreviewModeOptions<S>): { enabled: import("vue").Ref<boolean>; state: S extends void ? Preview["state"] : (NonNullable<S> & Preview["state"]); }; export {};