Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/rs/zerolog
/ ExampleNew
Function
ExampleNew
log_example_test.go:16–21 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
14
)
15
16
func
ExampleNew() {
17
log := zerolog.New(os.Stdout)
18
19
log.Info().Msg(
"hello world"
)
20
// Output: {"level":"info","message":"hello world"}
21
}
22
23
func
ExampleLogger_With() {
24
log := zerolog.New(os.Stdout).
Callers
nothing calls this directly
Calls
3
New
Function · 0.92
Msg
Method · 0.80
Info
Method · 0.65
Tested by
no test coverage detected
Used in the wild
real call sites across dependent graphs
searching dependent graphs…