Sanity Library Reference Docs
    Preparing search index...

    Interface LoggerConfig

    Configuration for the logging system

    interface LoggerConfig {
        enableInProduction?: boolean;
        handler?: LogHandler;
        internal?: boolean;
        level?: LogLevel;
        namespaces?: string[];
        timestamps?: boolean;
    }
    Index

    Properties

    enableInProduction?: boolean

    Enable in production builds

    false
    
    handler?: LogHandler

    Custom log handler (for testing or custom output)

    console methods
    
    internal?: boolean

    Enable internal/maintainer-level logging Shows RxJS streams, store internals, etc.

    false
    
    level?: LogLevel

    Minimum log level to output

    'warn'
    
    namespaces?: string[]

    Namespaces to enable. Use ['*'] for all namespaces

    []
    

    Available namespaces depend on which modules have logging integrated. Check the SDK documentation for the current list of instrumented modules.

    ['auth', 'document']
    
    timestamps?: boolean

    Enable timestamps in log output

    true