From 5c489893c8e0464f40b60650e19333098e650d7b Mon Sep 17 00:00:00 2001 From: Gireesh Punathil Date: Thu, 31 Oct 2024 11:17:47 +0530 Subject: [PATCH] doc: add a note on console stream behavior Many user reported issues show poor awareness of the nature of console streams. explicitly document that. --- doc/api/console.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/doc/api/console.md b/doc/api/console.md index 147a45eadb1203..1c966d094d1472 100644 --- a/doc/api/console.md +++ b/doc/api/console.md @@ -19,7 +19,11 @@ The module exports two specific components: _**Warning**_: The global console object's methods are neither consistently synchronous like the browser APIs they resemble, nor are they consistently -asynchronous like all other Node.js streams. See the [note on process I/O][] for +asynchronous like all other Node.js streams. Programs that desire to depend +on the synchronous / asynchronous behavior of the console functions should +first figure out the nature of console's backing stream. This is because the +stream is dependent on the underlying platform and standard stream +configuration of the current process. See the [note on process I/O][] for more information. Example using the global `console`: