-
Notifications
You must be signed in to change notification settings - Fork 30.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
console: console.table() uses colored inspect #20510
Conversation
This makes console.table() inspect objects with color if available like `console.log`.
cc @devsnek @TimothyGu @BridgeAR as per #18137 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks ok, although I would think this is patch not minor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
General note: we should likely consider adding more default options here as the defaults might have been manipulated by the user or modules. But that is out of the scope of this PR. |
Landed in 6af26b1 |
This makes `console.table()` inspect objects with color if available like `console.log()`. PR-URL: #20510 Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Jackson Tian <shyvo1987@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This makes `console.table()` inspect objects with color if available like `console.log()`. PR-URL: #20510 Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Jackson Tian <shyvo1987@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Notable Changes: * console: - make console.table() use colored inspect (TSUYUSATO Kitsune) #20510 * fs: - move fs/promises to fs.promises (cjihrig) #20504 * http: - added aborted property to request (Robert Nagy) #20094 * n-api: - initialize a module via a special symbol (Gabriel Schulhof) #20161 * src: - add public API to expose the main V8 Platform (Allen Yonghuang Wang) #20447 PR-URL: Coming Soon
This makes `console.table()` inspect objects with color if available like `console.log()`. PR-URL: #20510 Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Jackson Tian <shyvo1987@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Notable Changes: * console: - make console.table() use colored inspect (TSUYUSATO Kitsune) #20510 * fs: - move fs/promises to fs.promises (cjihrig) #20504 * http: - added aborted property to request (Robert Nagy) #20094 * n-api: - initialize a module via a special symbol (Gabriel Schulhof) #20161 * src: - add public API to expose the main V8 Platform (Allen Yonghuang Wang) #20447 PR-URL: #20606
This makes `console.table()` inspect objects with color if available like `console.log()`. PR-URL: #20510 Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Jackson Tian <shyvo1987@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Notable Changes: * console: - make console.table() use colored inspect (TSUYUSATO Kitsune) #20510 * fs: - move fs/promises to fs.promises (cjihrig) #20504 * http: - added aborted property to request (Robert Nagy) #20094 * n-api: - initialize a module via a special symbol (Gabriel Schulhof) #20161 * src: - add public API to expose the main V8 Platform (Allen Yonghuang Wang) #20447 PR-URL: #20606
Notable Changes: * console: - make console.table() use colored inspect (TSUYUSATO Kitsune) #20510 * fs: - move fs/promises to fs.promises (cjihrig) #20504 * http: - added aborted property to request (Robert Nagy) #20094 * n-api: - initialize a module via a special symbol (Gabriel Schulhof) #20161 * src: - add public API to expose the main V8 Platform (Allen Yonghuang Wang) #20447 PR-URL: #20606
This makes
console.table()
inspect objects with color if available likeconsole.log
.Currently
console.table
withtrue
,false
,null
orundefined
shows colored values because it callsconsole.log
internally.However
console.table
with objects does not show colored value at all.It seems a bug and I wish
console.table
shows colored values.I'm first time contributor. I have a questions: Is this PR change just a bug fixing? -- Or breaking change?
Probably it is the important concern of
nodejs/node
, which is used for versioning. I can't determine that. What do you think?Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes