{ "html": "
All packages are available via npm.
\n$ npm install @sentry/electron --save\n$ npm install @sentry/wizard --save-dev\n
Run the wizard to help you finish your setup:\nWith yarn
you can just call:
$ yarn sentry-wizard --integration=electron\n
If you only have npm
call:
$ node node_modules/.bin/sentry-wizard --integration=electron\n
sentry-wizard
will display recommended packages like electron-download which we need\nto symbolicate native crashes.\nThe wizard will also create a file called sentry.properties
(which contains\nyour account information) and sentry-symbols.js
which helps you with the symbol\nupload.
The following code should reside in the main process
and all renderer processes
:
const { SentryClient } = require('@sentry/electron');\n\nSentryClient.create({\n dsn: '___PRIVATE_DSN___',\n // ...\n});\n
This configuration will also take care of unhandled Promise rejections, which can be\nhandled in various ways. By default, Electron uses the standard JS API.\nTo learn more about handling promises, refer to Promises documentation.
\nThe wizard should create a file called sentry-symbols.js
which takes care of uploading\ndebug symbols to Sentry. Note that this is only necessary whenever you update your\nversion of electron. It usually takes quiet a while because it downloads debug symbols\nof electron and uploads them to Sentry so we can symbolicate your native crashes.\nYou can always execute the script by calling:
$ node sentry-symbols.js\n