JS console colors
Just wondering if there is a way to change the text color using
You can change the color of a console.log by adding %c to the beginning of your message and adding css as the second argument.
Please mark this comment as the answer if it helped. Thanks!
One of the most popular libraries to add colored text is called
However, it doesn't seem to be supported on replit at the moment. (see screenshot) :P
There is a way to do it.
Checkout this StackOverflow post. Basically, you can write something like this:
And have the output be red :)
I made a repl here if you want to check it out.