File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ Error handler for CLI applications.
1818- π [ Graceful exit] ( #-timeout )
1919- βοΈ [ Normalize] ( https://github.com/ehmicky/normalize-exception ) invalid errors
2020- π Log verbosity: [ message] ( #-silent ) , [ stack] ( #-stack ) , [ properties] ( #-props )
21- - π¨ Custom [ exit code] ( #-exitcode )
21+ - π¨ Custom [ exit code] ( #-exitcode ) and [ log function ] ( #-log )
2222- π₯ Exception-safe
2323
2424# Screenshot
@@ -163,6 +163,13 @@ Special values:
163163- ` Number.POSITIVE_INFINITY ` : Waits for ongoing tasks forever, without timing
164164 out
165165
166+ #### π log
167+
168+ _ Type_ : ` (string) => void ` \
169+ _ Default_ : ` console.error `
170+
171+ Function used to print the error message.
172+
166173#### π£ classes
167174
168175_ Type_ : ` object ` \
Original file line number Diff line number Diff line change @@ -44,6 +44,7 @@ export type Options = BeautifulErrorOptions & {
4444 readonly timeout ?: number
4545
4646 /**
47+ * Function used to print the error message.
4748 *
4849 * @default console.error
4950 */
You canβt perform that action at this time.
0 commit comments