Interface FileHandlerOptions
interface FileHandlerOptions {
bufferSize?: number;
filename: string;
formatter?: FormatterFunction;
mode?: LogMode;
}
bufferSize?: number;
filename: string;
formatter?: FormatterFunction;
mode?: LogMode;
}
Hierarchy
- BaseHandlerOptions
- FileHandlerOptions (view full)
Index
Properties
Properties
OptionalbufferSize
bufferSize ?: number
Buffer size for writing log messages to file, in bytes.
filename
filename: string
The filename to output to.
Optionalformatter
A function that formats log records.
Optionalmode
Log mode for the handler. Behavior of the log modes is as follows:
'a'- Default mode. Appends new log messages to the end of an existing log file, or create a new log file if none exists.'w'- Upon creation of the handler, any existing log file will be removed and a new one created.'x'- This will create a new log file and throw an error if one already exists.
Options for
FileHandler.