DEV Community

Discussion on: 5 JavaScript Console Methods That will Improve your Debugging Skills🚀

Collapse
 
bluefalconhd profile image
Hayes Dombroski • Edited

You can also apply css styling to certain messages in the console, if you need something to stand out. Use console.log("%cTEXT", "color: purple; font-size: 20px")

Collapse
 
qbentil profile image
Bentil Shadrack • Edited

Yes! that's also a great way of identifying the log messages at different run points in your code for easy debugging.

Thank you!🚀

Collapse
 
mahanjs profile image
mahan-js

Sye

Collapse
 
Sloan, the sloth mascot
Comment deleted
Collapse
 
bluefalconhd profile image
Hayes Dombroski

yep! I mistyped!

Collapse
 
pelv profile image
Alex Benfaremo

I've made a small npm package to better handle "tagged and colored" console.logs: npmjs.com/package/@pelv/frontlog

Nothing special but it has some fancy feature (hide log on prod build).
This post make me realise i should add the table and dir consoles, even if they doesn't really need styling.