How to use the @sentry/browser.captureMessage function in @sentry/browser

To help you get started, we’ve selected a few @sentry/browser 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 department-of-veterans-affairs / vets-website / src / applications / vaos / newAppointmentFlow.js View on Github external
return 'typeOfFacility';
              }
            }
          }

          // If no CC enabled systems and toc is podiatry, show modal
          if (isPodiatry(state)) {
            dispatch(showTypeOfCareUnavailableModal());
            return 'typeOfCare';
          }

          dispatch(updateFacilityType(FACILITY_TYPES.VAMC));
          return 'vaFacility';
        } catch (e) {
          Sentry.captureException(e);
          Sentry.captureMessage(
            'Community Care eligibility check failed with errors',
          );
          dispatch(updateFacilityType(FACILITY_TYPES.VAMC));
          return 'vaFacility';
        }
      }

      dispatch(updateFacilityType(FACILITY_TYPES.VAMC));
      return nextState;
    },
    previous: 'home',
github mozilla / fxa / packages / fxa-content-server / app / scripts / lib / channels / receivers / web-channel.js View on Github external
_reportError(error) {
    this._logger.error('WebChannel error:', error.message);
    Sentry.captureMessage('WebChannel error: ' + error.message, {
      // manually capture the stack as a custom field
      extra: {
        stackTrace: error.stack,
      },
    });
  },
github department-of-veterans-affairs / vets-website / src / applications / burials / helpers.jsx View on Github external
}).catch(res => {
    if (res instanceof Error) {
      Sentry.captureException(res);
      Sentry.captureMessage('vets_burial_poll_client_error');

      // keep polling because we know they submitted earlier
      // and this is likely a network error
      return Promise.resolve();
    }

    // if we get here, it's likely that we hit a server error
    return Promise.reject(res);
  });
}
github department-of-veterans-affairs / vets-website / src / applications / pensions / helpers.jsx View on Github external
.catch(res => {
      if (res instanceof Error) {
        Sentry.captureException(res);
        Sentry.captureMessage('vets_pension_poll_client_error');

        // keep polling because we know they submitted earlier
        // and this is likely a network error
        return Promise.resolve();
      }

      // if we get here, it's likely that we hit a server error
      return Promise.reject(res);
    });
}
github casual-simulation / aux / src / aux-server / aux-web / shared / AppManager.ts View on Github external
onUpdateFailed: () => {
                console.log('[ServiceWorker]: Update failed.');
                Sentry.captureMessage(
                    'Service Worker update failed',
                    Sentry.Severity.Error
                );
            },
            onInstalled: () => {
github department-of-veterans-affairs / vets-website / src / applications / disability-benefits / 526EZ / actions / index.js View on Github external
.catch(() => {
        Sentry.captureMessage('itf_fetch_failed');
        dispatch({ type: ITF_FETCH_FAILED });
      });
  };
github getsentry / sentry / src / sentry / static / sentry / app / components / createProject.jsx View on Github external
Sentry.withScope(scope => {
        scope.setExtra('props', this.props);
        scope.setExtra('state', this.state);
        Sentry.captureMessage('Onboarding no project name');
      });
    }
github Lumeer / web-ui / src / app / core / rest / interceptors / sentry.http-interceptor.ts View on Github external
private processError(error: any): void {
    if (error instanceof Error || error instanceof ErrorEvent) {
      Sentry.captureException(error);
    }

    if (error instanceof HttpErrorResponse) {
      if (error.error instanceof ErrorEvent) {
        Sentry.captureException(error.error);
      }

      Sentry.captureMessage(`${error.status}: ${error.error}`, Severity.Error);
    }

    Sentry.captureMessage(error);
  }
}