diff --git a/types/pino/index.d.ts b/types/pino/index.d.ts index 8cffeb2803..3c2a3f315b 100644 --- a/types/pino/index.d.ts +++ b/types/pino/index.d.ts @@ -11,6 +11,7 @@ // Cory Donkin // Adam Vigneaux // Austin Beer +// Michel Nemnom // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.7 @@ -461,6 +462,10 @@ declare namespace P { * The key in the JSON object to use for timestamp display. Default: "time". */ timestampKey?: string; + /** + * Format output of message, e.g. {level} - {pid} will output message: INFO - 1123 Default: `false`. + */ + messageFormat?: false | string; /** * If set to true, will add color information to the formatted output message. Default: `false`. */ diff --git a/types/pino/pino-tests.ts b/types/pino/pino-tests.ts index aa9e7c01a4..c5234cd488 100644 --- a/types/pino/pino-tests.ts +++ b/types/pino/pino-tests.ts @@ -165,9 +165,11 @@ const pretty = pino({ crlf: false, errorLikeObjectKeys: ['err', 'error'], errorProps: '', + messageFormat: false, + ignore: '', levelFirst: false, messageKey: 'msg', - timestampKey: "timestamp", + timestampKey: 'timestamp', translateTime: 'UTC:h:MM:ss TT Z', search: 'foo == `bar`' }