Sanity Library Reference Docs
    Preparing search index...
    interface DefineLiveOptions {
        browserToken?: string | false;
        client: SanityClient;
        serverToken?: string | false;
        strict?: boolean;
    }
    Index

    Properties

    browserToken?: string | false

    Token shared with the browser when <SanityLive includeDrafts /> opens a draft-capable live connection.

    Use a browser-safe token with the minimum read permissions needed for live previewing drafts outside Presentation Tool.

    client: SanityClient

    Sanity client used by sanityFetch() and <SanityLive />.

    serverToken?: string | false

    Token used by the server to query drafts and content release versions.

    This token is never shared with the browser unless you also pass it as browserToken.

    strict?: boolean

    Require explicit live-content options at every call site.

    When true, includeDrafts is required on <SanityLive /> and perspective/stega are required on sanityFetch(). This matches the explicit data flow needed inside Cache Components, where draftMode() and cookies() must be resolved outside 'use cache' boundaries.

    false