Socket
Socket
Sign inDemoInstall

webpack-bugsnag-plugins

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

webpack-bugsnag-plugins - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

source-map-uploader-plugin.js

5

index.js
const BugsnagBuildReporterPlugin = require('./build-reporter-plugin')
const BugsnagSourceMapUploaderPlugin = require('./source-map-uploader-plugin')
module.exports = {
BugsnagBuildReporterPlugin: BugsnagBuildReporterPlugin
BugsnagBuildReporterPlugin: BugsnagBuildReporterPlugin,
BugsnagSourceMapUploaderPlugin: BugsnagSourceMapUploaderPlugin
}

11

package.json
{
"name": "webpack-bugsnag-plugins",
"version": "1.0.0",
"version": "1.1.0",
"description": "Webpack plugins for common Bugsnag actions",

@@ -11,3 +11,3 @@ "keywords": [

"scripts": {
"test": "standard && tape test/build-reporter-plugin.test.js"
"test": "standard && tape test/**.test.js | tap-spec"
},

@@ -21,3 +21,6 @@ "repository": {

"devDependencies": {
"concat-stream": "^1.6.0",
"parse-formdata": "^1.0.2",
"standard": "^10.0.3",
"tap-spec": "^4.1.1",
"tape": "^4.8.0",

@@ -27,3 +30,5 @@ "webpack": "^3.10.0"

"dependencies": {
"bugsnag-build-reporter": "^1.0.0"
"bugsnag-build-reporter": "^1.0.0",
"bugsnag-sourcemaps": "^1.0.3",
"run-parallel-limit": "^1.0.3"
},

@@ -30,0 +35,0 @@ "standard": {

@@ -15,2 +15,4 @@ # webpack-bugsnag-plugins

### `new BugsnagBuildReporterPlugin(build, opts):`[`WebpackPlugin`](https://webpack.js.org/concepts/plugins/)
```js

@@ -20,4 +22,2 @@ const { BugsnagBuildReporterPlugin } = require('webpack-bugsnag-plugins')

### `BugsnagBuildReporterPlugin(build, opts): stream`
Reports your application's build to Bugsnag. It can auto detect source control from `.git`, `.hg` and `package.json`.

@@ -66,2 +66,45 @@ This plugin hooks into the `'after-emit'` event once all output files have been generated by the Webpack compiler. If anything causes the compilation to fail before this step, the build report will not get sent.

---
### `new BugsnagSourceMapUploaderPlugin(opts):`[`WebpackPlugin`](https://webpack.js.org/concepts/plugins/)
```js
const { BugsnagSourceMapUploaderPlugin } = require('webpack-bugsnag-plugins')
```
Upload your application's sourcemap(s) to Bugsnag. When Webpack is done producing output, this plugin detects sourcemaps for any output chunks and uploads them to Bugsnag.
- `opts` provide options to the sourcemap uploader
- `apiKey: string` your Bugsnag API key __[required]__
- `publicPath: string` the path to your bundled assets (as the browser will see them). This option must either be provided here, or as [`output.publicPath`](https://webpack.js.org/configuration/output/#output-publicpath) in your Webpack config.
- `appVersion: string` the version of the application you are building
- `overwrite: boolean` whether you want to overwrite previously uploaded sourcemaps
- `endpoint: string` post the build payload to a URL other than the default (`https://upload.bugsnag.com`)
#### Usage
```js
const { BugsnagSourceMapUploaderPlugin } = require('webpack-bugsnag-plugins')
module.exports = {
entry: './app.js',
devtool: 'source-map',
output: {
path: __dirname,
filename: './bundle.js',
publicPath: 'https://your-app.xyz/assets/'
},
plugins: [].concat(
// It's a good idea to only run this plugin when you're building a bundle
// that will be released, rather than for every development build
isDistEnv
? new BugsnagSourceMapUploaderPlugin({
apiKey: 'YOUR_API_KEY',
appVersion: '1.2.3'
})
: []
)
}
```
## Support

@@ -68,0 +111,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc