Sanity Library Reference Docs
    Preparing search index...

    Interface DefineSanityLiveOptionsAlpha

    CAUTION: This API does not follow semver and could have breaking changes in future minor releases.

    interface DefineSanityLiveOptions {
        browserToken?: string | false;
        client: SanityClient;
        serverToken?: string | false;
    }
    Index

    Properties

    browserToken?: string | false

    Optional. This token is shared with the browser, and should only have access to query published documents. It is used to setup a Live Draft Content EventSource connection, and enables live previewing drafts stand-alone, outside of Presentation Tool.

    client: SanityClient

    Required for sanityFetch and SanityLive to work

    serverToken?: string | false

    Optional. If provided then the token needs to have permissions to query documents with drafts. prefixes in order for perspective: 'drafts' to work. This token is not shared with the browser.