@@ -173,8 +173,6 @@ myEmitter.emit('error', new Error('whoops!'));
173173
174174## Capture rejections of promises
175175
176- > Stability: 1 - captureRejections is experimental.
177-
178176Using ` async ` functions with event handlers is problematic, because it
179177can lead to an unhandled rejection in case of a thrown exception:
180178
@@ -741,10 +739,12 @@ emitter.emit('log');
741739added:
742740 - v13.4.0
743741 - v12.16.0
742+ changes:
743+ - version: REPLACEME
744+ pr-url: https://github.com/nodejs/node/pull/41267
745+ description: No longer experimental.
744746-->
745747
746- > Stability: 1 - captureRejections is experimental.
747-
748748* ` err ` Error
749749* ` eventName ` {string|symbol}
750750* ` ...args ` {any}
@@ -1028,10 +1028,12 @@ foo().then(() => console.log('done'));
10281028added:
10291029 - v13.4.0
10301030 - v12.16.0
1031+ changes:
1032+ - version: REPLACEME
1033+ pr-url: https://github.com/nodejs/node/pull/41267
1034+ description: No longer experimental.
10311035-->
10321036
1033- > Stability: 1 - captureRejections is experimental.
1034-
10351037Value: {boolean}
10361038
10371039Change the default ` captureRejections ` option on all new ` EventEmitter ` objects.
@@ -1040,12 +1042,14 @@ Change the default `captureRejections` option on all new `EventEmitter` objects.
10401042
10411043<!-- YAML
10421044added:
1043- - v13.4.0
1044- - v12.16.0
1045+ - v13.4.0
1046+ - v12.16.0
1047+ changes:
1048+ - version: REPLACEME
1049+ pr-url: https://github.com/nodejs/node/pull/41267
1050+ description: No longer experimental.
10451051-->
10461052
1047- > Stability: 1 - captureRejections is experimental.
1048-
10491053Value: ` Symbol.for('nodejs.rejection') `
10501054
10511055See how to write a custom [ rejection handler] [ rejection ] .
0 commit comments