From 02ec52668cdcd673cedb3de5f776dd653e47fcd9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20Og=C3=B3rek?= Date: Wed, 3 Jul 2019 16:42:18 +0200 Subject: [PATCH 1/2] docs: Update docs on how to turn off onunhandledrejections --- src/collections/_documentation/platforms/javascript/index.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/collections/_documentation/platforms/javascript/index.md b/src/collections/_documentation/platforms/javascript/index.md index 1deaee7addf13..08145dfce6d2f 100644 --- a/src/collections/_documentation/platforms/javascript/index.md +++ b/src/collections/_documentation/platforms/javascript/index.md @@ -67,7 +67,7 @@ By default, Sentry for JavaScript captures unhandled promise rejections as descr Configuration may be required if you are using a third-party library to implement promises. -Most promise libraries have a global hook for capturing unhandled errors. You may want to disable default behavior by setting `captureUnhandledRejections` option to `false` and manually hook into such event handler and call `Sentry.captureException` or `Sentry.captureMessage` directly. +Most promise libraries have a global hook for capturing unhandled errors. You may want to disable default behavior by changing `onunhandledrejection` option to `false` in your [GlobalHandlers]({%- link _documentation/platforms/javascript/index.md#globalhandlers -%}) integration and manually hook into such event handler and call `Sentry.captureException` or `Sentry.captureMessage` directly. For example, the [RSVP.js library](https://github.com/tildeio/rsvp.js/) (used by Ember.js) allows you to bind an event handler to a [global error event](https://github.com/tildeio/rsvp.js#error-handling). @@ -77,7 +77,7 @@ RSVP.on('error', function(reason) { }); ``` -[Bluebird](http://bluebirdjs.com/docs/getting-started.html) and other promise libraries report unhandled rejections to a global DOM event, `unhandledRejection`. In this case, you don't need to do anything; we've already got you covered with the default `captureUnhandledRejections: true` setting. +[Bluebird](http://bluebirdjs.com/docs/getting-started.html) and other promise libraries report unhandled rejections to a global DOM event, `unhandledRejection`. In this case, you don't need to do anything; we've already got you covered with the default [GlobalHandlers]({%- link _documentation/platforms/javascript/index.md#globalhandlers -%}) integration and its `onhandledrejection: true` setting. Please consult your promise library documentation on how to hook into its global unhandled rejection handler, if it exposes one. From 7e4538c86aca14b7c5512952b05e8a4640c19376 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20Og=C3=B3rek?= Date: Fri, 12 Jul 2019 23:13:45 +0200 Subject: [PATCH 2/2] fix hash links --- src/collections/_documentation/platforms/javascript/index.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/collections/_documentation/platforms/javascript/index.md b/src/collections/_documentation/platforms/javascript/index.md index 08145dfce6d2f..bf21ddb45a475 100644 --- a/src/collections/_documentation/platforms/javascript/index.md +++ b/src/collections/_documentation/platforms/javascript/index.md @@ -67,7 +67,7 @@ By default, Sentry for JavaScript captures unhandled promise rejections as descr Configuration may be required if you are using a third-party library to implement promises. -Most promise libraries have a global hook for capturing unhandled errors. You may want to disable default behavior by changing `onunhandledrejection` option to `false` in your [GlobalHandlers]({%- link _documentation/platforms/javascript/index.md#globalhandlers -%}) integration and manually hook into such event handler and call `Sentry.captureException` or `Sentry.captureMessage` directly. +Most promise libraries have a global hook for capturing unhandled errors. You may want to disable default behavior by changing `onunhandledrejection` option to `false` in your [GlobalHandlers]({%- link _documentation/platforms/javascript/index.md -%}#globalhandlers) integration and manually hook into such event handler and call `Sentry.captureException` or `Sentry.captureMessage` directly. For example, the [RSVP.js library](https://github.com/tildeio/rsvp.js/) (used by Ember.js) allows you to bind an event handler to a [global error event](https://github.com/tildeio/rsvp.js#error-handling). @@ -77,7 +77,7 @@ RSVP.on('error', function(reason) { }); ``` -[Bluebird](http://bluebirdjs.com/docs/getting-started.html) and other promise libraries report unhandled rejections to a global DOM event, `unhandledRejection`. In this case, you don't need to do anything; we've already got you covered with the default [GlobalHandlers]({%- link _documentation/platforms/javascript/index.md#globalhandlers -%}) integration and its `onhandledrejection: true` setting. +[Bluebird](http://bluebirdjs.com/docs/getting-started.html) and other promise libraries report unhandled rejections to a global DOM event, `unhandledRejection`. In this case, you don't need to do anything; we've already got you covered with the default [GlobalHandlers]({%- link _documentation/platforms/javascript/index.md -%}#globalhandlers) integration and its `onhandledrejection: true` setting. Please consult your promise library documentation on how to hook into its global unhandled rejection handler, if it exposes one.