How to use the @sentry/electron.withScope function in @sentry/electron

To help you get started, we’ve selected a few @sentry/electron examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github poooi / poi / views / components / tab-area / index.es View on Github external
componentDidCatch(error, info) {
    console.error(error, info)
    Sentry.withScope(scope => {
      scope.setExtra('componentStack', info.componentStack)
      scope.setTag('area', 'poi')
      const eventId = Sentry.captureException(error)
      this.setState({
        hasError: true,
        error,
        info,
        eventId,
      })
    })
  }