question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

improve readability of console log - alternating colors

See original GitHub issue

Checklist

proposal

The console log could have alternating colors to improve readability:

line 1: white
line 2: gray
line 3: white
line 4: gray
line 5: white
line 6: gray
etc.

rationale

I find it a bit difficult to read, when the screen is full of text: img1 Alternating colors would improve readability IMO: img2

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
Zirrocommented, Jan 12, 2022

Showing alternating colors for each line sounds like it would be more within the domain of the terminal emulator itself - by applying a theme for example - rather than the textual interface of the application running within it.

The common way to use color to increase CLI readability looks to be by coloring parts of the text itself, depending on the type of output it represents. The output from aria2 is a good example of this, and yt-dlp could probably make good use of it too (as long as an option to turn it off is also provided for those who’d prefer that).

0reactions
chrizillacommented, Jan 12, 2022

Ok, I see what you mean now.

But as you point out, you already use colors for some output (apparently not ouf of scope). I don’t yet get why my proposal is any different from what you are already doing (highlighting some stuff).

Users could still turn this behaviour on/off in the options or override that with a theme as shown in your stackoverflow link, right?

So in case you agree that it’s useful for better readability, is there any offsetting conflict/downside/problem that led to your decision ?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spring-Boot, improve readability on your console log
xml), is possible use some colors inside the pattern color. The colors supported are: blue, cyan, faint, green, magenta, red, yellow. <appender name="stdout" ......
Read more >
Advanced Console Logging - Styling - Pixel Pixel
Make error messages more readable. ... Improve clarity and accessibility. ... e.g. console.log('%cUsing multiple styles', 'color: orange; background-color: ...
Read more >
google chrome - Colors in JavaScript console - Stack Overflow
It improves the readability and reduces the complexity in the code. It is too easy to maintain and further extend according to your...
Read more >
These Console Log Tricks Will Make Your Life MUCH Easier
Did you know console log could do these tricks? From creating tables to styling with colors, console. log is one of the most...
Read more >
Colorful Console Message | SamanthaMing.com
# Colorful Console Message · // Put this in your browser console console.log('%cHello', 'color: green; background: yellow; font-size: 30px'); · console.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found