30 lines
781 B
JavaScript
30 lines
781 B
JavaScript
Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
|
const core = require('@sentry/core');
|
|
const index = require('./index.js');
|
|
|
|
// TODO (v8): Remove this entire file and the `enableAnrDetection` export
|
|
|
|
/**
|
|
* @deprecated Use the `Anr` integration instead.
|
|
*
|
|
* ```ts
|
|
* import * as Sentry from '@sentry/node';
|
|
*
|
|
* Sentry.init({
|
|
* dsn: '__DSN__',
|
|
* integrations: [new Sentry.Integrations.Anr({ captureStackTrace: true })],
|
|
* });
|
|
* ```
|
|
*/
|
|
function enableAnrDetection(options) {
|
|
const client = core.getClient() ;
|
|
// eslint-disable-next-line deprecation/deprecation
|
|
const integration = new index.Anr(options);
|
|
integration.setup(client);
|
|
return Promise.resolve();
|
|
}
|
|
|
|
exports.enableAnrDetection = enableAnrDetection;
|
|
//# sourceMappingURL=legacy.js.map
|