README
sentry-sourcemap-plugin
@sentry/webpack-plugin
extended webpack plugin.
Sentry automatically deletes the SourceMap file after uploading it Map file.
⚠️ This plugin is configured with some initial values by default::
- release: '1.0.0', automatically read the
version
in the current projectpackage.json
。 - include: './dist'。
- configFile: '.sentryclirc'。
Use
Install
💡
@longwoo/sentry-sourcemap-plugin
already contains@sentry/webpack-plugin
plugin, no need to install it. The configuration is consistent with@sentry/webpack-plugin
.
npm install @longwoo/sentry-sourcemap-plugin --save-dev
# or
yarn add @longwoo/sentry-sourcemap-plugin -D
Vue project
Add the following configuration in the vue.config.js
file:
const { SentrySourcemapPlugin } = require('@longwoo/sentry-sourcemap-plugin')
module.exports = {
configureWebpack: config => {
config.plugins.push(new SentrySourcemapPlugin())
}
}
Webpack
Added in the plugins
option of the webpack.config.js
file:
const { SentrySourcemapPlugin } = require('@longwoo/sentry-sourcemap-plugin')
module.exports = {
plugins: [
new SentrySourcemapPlugin()
]
}