Sanity Library Reference Docs
    Preparing search index...

    Interface PluginOptionsBeta

    interface PluginOptions {
        __internal_tasks?: { footerAction: ReactNode };
        document?: DocumentPluginOptions;
        form?: SanityFormConfig;
        mediaLibrary?: MediaLibraryConfig;
        name: string;
        onUncaughtError?: (error: Error, errorInfo: ErrorInfo) => void;
        plugins?: PluginOptions[];
        schema?: SchemaPluginOptions;
        search?: {
            enableLegacySearch?: boolean;
            strategy?: "groqLegacy" | "groq2024";
            unstable_partialIndexing?: { enabled: boolean };
        };
        studio?: {};
        tools?: Tool<any>[]
        | ComposableOption<Tool<any>[], ConfigContext>;
    }
    Index

    Properties

    __internal_tasks?: { footerAction: ReactNode }
    document?: DocumentPluginOptions
    mediaLibrary?: MediaLibraryConfig

    Config for the Sanity Media Library asset source integration.

    name: string
    onUncaughtError?: (error: Error, errorInfo: ErrorInfo) => void

    Configuration for error handling.

    plugins?: PluginOptions[]
    schema?: SchemaPluginOptions
    search?: {
        enableLegacySearch?: boolean;
        strategy?: "groqLegacy" | "groq2024";
        unstable_partialIndexing?: { enabled: boolean };
    }

    Type declaration

    • OptionalenableLegacySearch?: boolean

      Enables the legacy Query API search strategy.

      Use search.strategy instead.

    • Optionalstrategy?: "groqLegacy" | "groq2024"

      Control the strategy used for searching documents. This should generally only be used if you wish to try experimental search strategies.

      This option takes precedence over the deprecated search.enableLegacySearch option.

      Can be one of:

      • "groqLegacy" (default): Use client-side tokenization and schema introspection to search using the GROQ Query API.
      • "groq2024": (experimental) Perform full text searching using the GROQ Query API and its new text::matchQuery function.
    • Optionalunstable_partialIndexing?: { enabled: boolean }
    studio?: {}
    tools?: Tool<any>[] | ComposableOption<Tool<any>[], ConfigContext>