1
0
mirror of https://github.com/go-kratos/kratos.git synced 2025-01-10 00:29:01 +02:00
kratos/log/README.md

16 lines
249 B
Markdown
Raw Normal View History

2021-02-17 11:14:47 +02:00
# Log
## Usage
### Structured logging
```
logger := stdlog.NewLogger(stdlog.Writer(os.Stdout))
log := log.NewHelper("module_name", logger)
// Levels
log.Info("some log")
log.Infof("format %s", "some log")
log.Infow("field_name", "some log")
```