@herdwatch/sentry-cordova
v1.7.3-fix.1
Published
Official Sentry SDK for Cordova
Readme
Why this fork exists
Forked from upstream because Sentry archived it and no longer maintains it (see the notice below) — we still need it for error reporting on Cordova/Ionic, so we keep it compatible with current native Sentry SDKs ourselves and publish under the @herdwatch npm scope.
Published as @herdwatch/sentry-cordova.
Based on upstream v1.7.3. Changes from upstream:
- Upgraded the JS-side Sentry SDK dependency from v7 (
@sentry/[email protected]) to v8 (@sentry/[email protected]) — upstream's ownmainis still on v7. This meant rewriting every import that used to come from the now-retired@sentry/types/@sentry/utilspackages, since v8 consolidated them into@sentry/core. - Bumped the native
sentry-cocoadependency ahead of upstream's own pin and fixed the resulting iOS build break (SentryOptions+HybridSDKscategory replaced withSentryOptionsInternal) — upstream has since made the same native fix independently. - Republished under the
@herdwatch/sentry-cordovanpm scope.
[!IMPORTANT] Cordova is being superseded by modern alternatives like Capacitor. This codebase is no longer maintained by Sentry. If you are starting a new project or planning a migration, consider using Sentry Capacitor, Sentry React Native, or Sentry Flutter instead.
===========
Bad software is everywhere, and we're tired of it. Sentry is on a mission to help developers write better software faster, so we can get back to enjoying technology. If you want to join us Check out our open positions
This is a beta release
Usage
Cordova in index.html onDeviceReady function:
onDeviceReady: function() {
...
var Sentry = cordova.require("sentry-cordova.Sentry");
Sentry.init({ dsn: '___PUBLIC_DSN___' });
...
}Ionic in your app.module.ts:
...
import * as Sentry from 'sentry-cordova';
...
Sentry.init({ dsn: '___PUBLIC_DSN___' });Documentation
[!WARNING] Example and sample code in is unmaintained. Sample code may contain security vulnerabilities, should never be used in production, and exists only for illustrative purposes.
