Skip to content

Log level

A log level is a string that can be used to filter log messages. The default log level is info. Log levels are defined in the zerolog package.

The following levels are available :

  • debug
  • info
  • warn
  • error
  • fatal
  • panic
  • trace
(...)

func main() {

    zr.Setup(
        zr.WithCustomLevel(zr.LevelDebug()),
    )

    log.Debug().Msg("hello world")

}