Create console appender
createConsoleAppender(layout = layoutSimple)
The layout to be used by the appender.
Creates an appender that will write to the console.
appender <- createConsoleAppender(layout = layoutTimestamp)
logger <- createLogger(name = "SIMPLE",
threshold = "INFO",
appenders = list(appender))
registerLogger(logger)
logTrace("This event is below the threshold (INFO)")
logInfo("Hello world")
#> Hello world
#> 2024-08-23 08:25:53 Hello world
unregisterLogger("SIMPLE")
#> [1] TRUE