From db8c841e580eda7bcc0ecf907b57a94ce4e3c3e7 Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Thu, 17 Nov 2022 10:54:43 +0100 Subject: [PATCH] Add support for passing `VFileMessage` to `message` in types --- lib/index.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/index.js b/lib/index.js index 85fb667c..1e1d4b7b 100644 --- a/lib/index.js +++ b/lib/index.js @@ -309,7 +309,7 @@ export class VFile { * associates it with the file by adding it to `vfile.messages` and setting * `message.file` to the current filepath. * - * @param {string|Error} reason + * @param {string|Error|VFileMessage} reason * Human readable reason for the message, uses the stack and message of the error if given. * @param {Node|NodeLike|Position|Point} [place] * Place where the message occurred in the file. @@ -337,7 +337,7 @@ export class VFile { * Like `VFile#message()`, but associates an informational message where * `fatal` is set to `null`. * - * @param {string|Error} reason + * @param {string|Error|VFileMessage} reason * Human readable reason for the message, uses the stack and message of the error if given. * @param {Node|NodeLike|Position|Point} [place] * Place where the message occurred in the file. @@ -360,7 +360,7 @@ export class VFile { * * > 👉 **Note**: a fatal error means that a file is no longer processable. * - * @param {string|Error} reason + * @param {string|Error|VFileMessage} reason * Human readable reason for the message, uses the stack and message of the error if given. * @param {Node|NodeLike|Position|Point} [place] * Place where the message occurred in the file.