sentry-stacktrace-fixer
v1.0.0
Published
fixes sourcemap stacktrace filenames for sentry events on the client side
Downloads
17,030
Readme
Installation
yarn add sentry-stacktrace-fixer
Usage
import * as Sentry from '@sentry/browser';
import { stripStacktraceFilenamesBeforePrefix } from 'sentry-stacktrace-fixer';
const beforeSend = stripStacktraceFilenamesBeforePrefix(BUNDLE_PREFIX);
if (process.env.NODE_ENV === 'production') {
Sentry.init({
dsn: SENTRY_KEY,
release: PRODUCT + '@' + VERSION,
beforeSend
});
}