mirror of https://github.com/gofiber/fiber.git
docs(logger): Improve documentation based on markdownlint-cli2
parent
e647f6f94d
commit
6b8e5b3b49
|
@ -191,7 +191,7 @@ Logger provides predefined formats that you can use by name or directly by speci
|
|||
| default | `FormatDefault` | `"[${time}] ${ip} ${status} - ${latency} ${method} ${path} ${error}\n"` | Fiber's default logger format. |
|
||||
| common | `FormatCommonLog` | `"${ip} - - [${time}] "${method} ${url} ${protocol}" ${status} ${bytesSent}\n"` | Common Log Format (CLF) used in web server logs. |
|
||||
| combined | `FormatCombined` | `"${ip} - - [${time}] "${method} ${url} ${protocol}" ${status} ${bytesSent} "${referer}" "${ua}"\n"` | CLF format plus the `referer` and `user agent` fields. |
|
||||
| json | `FormatJSON` | `"{time: ${time}, ip: ${ip}, method: ${method}, url: ${url}, status: ${status}, bytesSent: ${bytesSent}}\n"` | JSON format for structured logging.
|
||||
| json | `FormatJSON` | `"{time: ${time}, ip: ${ip}, method: ${method}, url: ${url}, status: ${status}, bytesSent: ${bytesSent}}\n"` | JSON format for structured logging. |
|
||||
|
||||
## Constants
|
||||
|
||||
|
|
|
@ -957,6 +957,7 @@ app.Use(logger.New(logger.Config{
|
|||
Format: "json", // or logger.FormatJSON,
|
||||
}))
|
||||
```
|
||||
|
||||
</details>
|
||||
|
||||
### Filesystem
|
||||
|
|
Loading…
Reference in New Issue