A function that handles the log data.
Options for filtering log data prior to sending to the handler.
A function that determines if handler is called
The maximum log level.
A regex that the log message should match.
A list of tags that the log data should match.
The handler function that was added.
Default log event handler.
Prints the event data to stderr:
If in Node.js, and the
The log data to handle
Whether or not to exit the process on the first error. Defaults to true
.
The maximum log level to print. Defaults to info
.
Whether or not to show any stack traces for errors. Defaults to false
.
Escape a string for inclusion in JSON.
Based on the list at https://www.json.org minus the backspace character (U+0008)
The string to escape
Get a logger for the specific application or package.
Each of the returned logger functions are the public interface for posting log messages.
The unique application or package name
Get all handlers.
Remove a handler.
The handler function to remove.
Remove all handlers.
Replace all existing handlers with a new handler.
This is a convenience function that can be used to replace the default handler with a new one which logs to the console.
Generated using TypeDoc
Add a handler.