feat issue #1341 (Layouts) : fix typo & add related doc entry

This commit is contained in:
Benoît Lefèvre 2022-11-28 10:04:25 +01:00
parent aedef32bb9
commit ab43399200
2 changed files with 3 additions and 1 deletions

View File

@ -134,6 +134,8 @@ Fields can be any of:
- `%c` log category
- `%h` hostname
- `%m` log data
- `%m{l}`, where l is an integer, log data.slice(l)
- `%m{l,u}`, where l and u are integers, log data.slice(l,u)
- `%d` date, formatted - default is `ISO8601`, format options are: `ISO8601`, `ISO8601_WITH_TZ_OFFSET`, `ABSOLUTETIME`, `DATETIME`, or any string compatible with the [date-format](https://www.npmjs.com/package/date-format) library. e.g. `%d{DATETIME}`, `%d{yyyy/MM/dd-hh.mm.ss}`
- `%%` % - for when you want a literal `%` in your output
- `%n` newline

View File

@ -102,7 +102,7 @@ function dummyLayout(loggingEvent) {
* - %h hostname
* - %m log data
* - %m{l}, where l is an integer : log data.slice(l)
* - %m{l,u}, where l ans u are integers : log data.slice(l,u)
* - %m{l,u}, where l and u are integers : log data.slice(l,u)
* - %d date in constious formats
* - %% %
* - %n newline