Takaro - v0.6.0
    Preparing search index...

    Variable consoleLoggingIntegrationConst Experimental

    consoleLoggingIntegration: (
        options?: Partial<CaptureConsoleOptions>,
    ) => Integration

    Captures calls to the console API as logs in Sentry. Requires the enableLogs option to be enabled.

    This feature is experimental and may be changed or removed in future versions.

    By default the integration instruments console.debug, console.info, console.warn, console.error, console.log, console.trace, and console.assert. You can use the levels option to customize which levels are captured.

    Type Declaration

      • (options?: Partial<CaptureConsoleOptions>): Integration
      • Parameters

        • Optionaloptions: Partial<CaptureConsoleOptions>

        Returns Integration

    import * as Sentry from '@sentry/browser';

    Sentry.init({
    enableLogs: true,
    integrations: [Sentry.consoleLoggingIntegration({ levels: ['error', 'warn'] })],
    });