File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -6,10 +6,20 @@ To get started, you need to configure Raven to use your Sentry DSN:
6
6
.. sourcecode :: javascript
7
7
8
8
var Raven = require('raven');
9
- Raven.config('___PUBLIC_DSN___').install()
9
+ Raven.config('___PUBLIC_DSN___').install();
10
10
11
11
At this point, Raven is ready to capture any uncaught exceptions.
12
12
13
+ Note that the ``install `` method can optionally take a callback function that is invoked if a fatal, non-recoverable error occurs.
14
+ You can use this callback to perform any cleanup that should occur before the Node process exits.
15
+
16
+ .. sourcecode :: javascript
17
+
18
+ Raven.config('___PUBLIC_DSN___').install(function (err, initialErr, eventId) {
19
+ console.error(err);
20
+ process.exit(1);
21
+ });
22
+
13
23
Optional settings
14
24
-----------------
15
25
@@ -18,8 +28,8 @@ Optional settings
18
28
.. sourcecode :: javascript
19
29
20
30
Raven.config('___PUBLIC_DSN___', {
21
- release: '1.3.0'
22
- }).install()
31
+ release: '1.3.0'
32
+ }).install();
23
33
24
34
Those configuration options are documented below:
25
35
You can’t perform that action at this time.
0 commit comments