Skip to content

Commit 8445cfa

Browse files
committed
docs: 📝 simplify documentation and link to docs pages
1 parent cce4e19 commit 8445cfa

File tree

1 file changed

+2
-74
lines changed

1 file changed

+2
-74
lines changed

README.md

Lines changed: 2 additions & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -30,46 +30,7 @@ const { BugsnagBuildReporterPlugin } = require('webpack-bugsnag-plugins')
3030

3131
Reports your application's build to BugSnag. It can auto detect source control from `.git`, `.hg` and `package.json`. 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.
3232

33-
- `build` describes the build you are reporting to Bugsnag
34-
- `apiKey: string` your Bugsnag API key __[required]__
35-
- `appVersion: string` the version of the application you are building __[required]__
36-
- `releaseStage: string` `'production'`, `'staging'` etc. (leave blank if this build can be released to different `releaseStage`s)
37-
- `sourceControl: object` an object describing the source control of the build (if not specified, the module will attempt to detect source control information from `.git`, `.hg` and the nearest `package.json`)
38-
- `provider: string` can be one of: `'github'`, `'github-enterprise'`, `'gitlab'`, `'gitlab-onpremise'`, `'bitbucket'`, `'bitbucket-server'`
39-
- `repository: string` a URL (`git`/`ssh`/`https`) pointing to the repository, or webpage representing the repository
40-
- `revision: string` the unique identifier for the commit (e.g. git SHA)
41-
- `builderName: string` the name of the person/machine that created this build (defaults to the result of the `whoami` command)
42-
- `autoAssignRelease: boolean` automatically associate this build with any new error events and sessions that are received for the `releaseStage` until a subsequent build notification is received. If this is set to `true` and no `releaseStage` is provided the build will be applied to `'production'`.
43-
- `metadata: object` an object describing key/value pairs containing any custom build information that provides useful metadata about the build. e.g. build configuration parameters, versions of dependencies, reason for the build etc.
44-
- `opts`
45-
- `logLevel: string` the minimum severity of log to output (`'debug'`, `'info'`, `'warn'`, `'error'`), default `'warn'`
46-
- `logger: object` provide a different logger object `{ debug, info, warn, error }`
47-
- `path: string` the path to search for source control info, defaults to `process.cwd()`
48-
- `endpoint: string` post the build payload to a URL other than the default (`https://build.bugsnag.com`)
49-
50-
#### Usage
51-
52-
```js
53-
const { BugsnagBuildReporterPlugin } = require('webpack-bugsnag-plugins')
54-
55-
module.exports = {
56-
entry: './app.js',
57-
output: {
58-
path: __dirname,
59-
filename: './bundle.js'
60-
},
61-
plugins: [].concat(
62-
// It's a good idea to only run this plugin when you're building a bundle
63-
// that will be released, rather than for every development build
64-
isDistEnv
65-
? new BugsnagBuildReporterPlugin({
66-
apiKey: 'YOUR_API_KEY',
67-
appVersion: '1.2.3'
68-
}, { /* opts */ })
69-
: []
70-
)
71-
}
72-
```
33+
Please see our [documentation](https://docs.bugsnag.com/build-integrations/webpack/#reporting-builds) for further details.
7334

7435
---
7536

@@ -81,40 +42,7 @@ const { BugsnagSourceMapUploaderPlugin } = require('webpack-bugsnag-plugins')
8142

8243
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.
8344

84-
- `opts` provide options to the sourcemap uploader
85-
- `apiKey: string` your Bugsnag API key __[required]__
86-
- `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.
87-
- `appVersion: string` the version of the application you are building (defaults to the `version` set in your project's package.json file, if one is specified there)
88-
- `codeBundleId: string` the codeBundleId (e.g. for NativeScript projects)
89-
- `overwrite: boolean` whether you want to overwrite previously uploaded sourcemaps
90-
- `endpoint: string` post the build payload to a URL other than the default (`https://upload.bugsnag.com`)
91-
- `ignoredBundleExtensions: string[]` a list of bundle file extensions which shouldn't be uploaded (default `[ '.css' ]`)
92-
93-
#### Usage
94-
95-
```js
96-
const { BugsnagSourceMapUploaderPlugin } = require('webpack-bugsnag-plugins')
97-
98-
module.exports = {
99-
entry: './app.js',
100-
devtool: 'source-map',
101-
output: {
102-
path: __dirname,
103-
filename: './bundle.js',
104-
publicPath: 'https://your-app.xyz/assets/'
105-
},
106-
plugins: [].concat(
107-
// It's a good idea to only run this plugin when you're building a bundle
108-
// that will be released, rather than for every development build
109-
isDistEnv
110-
? new BugsnagSourceMapUploaderPlugin({
111-
apiKey: 'YOUR_API_KEY',
112-
appVersion: '1.2.3'
113-
})
114-
: []
115-
)
116-
}
117-
```
45+
Please see our [documentation](https://docs.bugsnag.com/build-integrations/webpack/#uploading-source-maps) for further details.
11846

11947
## Supported Webpack versions
12048

0 commit comments

Comments
 (0)