Skip to content

Commit 2486d87

Browse files
committed
Update changelog
1 parent f44ff68 commit 2486d87

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

CHANGELOG.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,12 @@ The npm package size has been greatly reduced.
77
## Pretty-printing
88

99
Errors are not pretty-printed anymore. As a consequence, the `colors` option was
10-
removed. The [`onError` option](README.md#onerror) can be used instead to
11-
customize how the errors are printed. It receives the original process error,
12-
with its `name` left unchanged.
10+
removed.
11+
12+
The [`onError` option](README.md#onerror) can be used instead to customize how
13+
the errors are printed. It receives the original process error. The process
14+
error event is now passed as a second argument instead of being set as
15+
`error.name`.
1316

1417
Before:
1518

@@ -27,8 +30,8 @@ After:
2730

2831
```js
2932
logProcessErrors({
30-
onError(error, reason) {
31-
if (reason === 'uncaughtException') {
33+
onError(error, event) {
34+
if (event === 'uncaughtException') {
3235
console.error(error)
3336
}
3437
},

0 commit comments

Comments
 (0)