Sanity Library Reference Docs
    Preparing search index...

    What an application is currently showing: the Comlink agent resource context, made generic.

    interface ApplicationContext {
        document: { id: string } | null;
        resource: { id: string; type: "dataset" | "canvas" | "media-library" };
    }
    Index

    Properties

    Properties

    document: { id: string } | null

    The open document, or null when none is open.

    resource: { id: string; type: "dataset" | "canvas" | "media-library" }

    The resource the application is working in. Types follow @sanity/client's resource config.