Repository Details
Shared by
HelloGitHub Rating
0 ratings
一个速度快、专门用于输出 JSON 格式日志的库
Past 7 days Received -2 stars ✨
Use arrow keys to explore dates, Home and End for the first and last date, Escape to dismiss.| Date | Star | Daily change |
|---|---|---|
| 周二 | 12,535 | — |
| 周三 | 12,536 | +1 |
| 周四 | 12,537 | +1 |
| 周五 | 12,535 | -2 |
| 周六 | 12,535 | 0 |
| 周日 | 12,535 | 0 |
| 周一 | 12,533 | -2 |
12.5k
Stars
No
Chinese
Go
Language
Yes
Active
180
Contributors
169
Issues
No
Organization
None
Latest
715
Forks
MIT
License

一个速度快、专门用于输出 JSON 格式日志的库。还在为解析不规则的日志而烦恼吗?有了 zerolog 你可以跳起来了!当然它还有低效但可在控制台输出漂亮日志的模式,快去试试吧。示例代码:
```go
package main
import (
"github.com/rs/zerolog"
"github.com/rs/zerolog/log"
)
func main() {
zerolog.TimeFieldFormat = zerolog.TimeFormatUnix
log.Info().Msg("hello world")
}
// Output: {"time":1516134303,"level":"info","message":"hello world"}
```
Included in:
Vol.43
Comments
Rating:
No comments yet