Loggit
Loggit sends Pooka events to Erlang/OTP Logger. It adds a console formatter and a typed, bounded event collector for integrations such as an error tracker.
module main
import loggit.{Colour, Level}
main() {
let assert Ok(_) = loggit.install_console(Colour.Auto)
let assert Ok(_) = loggit.set_level(Level.Info)
loggit.log(Level.Info, "request served", [
#("request_id", "req-42"),
#("route", "/books")
])
}
The default console prints a short line such as [info] request served.
For UTC timestamps, fields, and stack frames, call
loggit.install_console_with_style(Colour.Auto, ConsoleStyle.Detailed)
with ConsoleStyle imported. Structured collectors receive the full event
with either format.
See the integration guide for scoped fields, native OTP crashes and collector behaviour.
Licence
Licensed under the Apache License, Version 2.0.