@gvray/logger / supportsColor
Function: supportsColor()
supportsColor():
boolean
Defined in: utils.ts:156
Returns true when the current environment can render colored output.
Browsers return true — DevTools renders CSS %c styling. Node returns true only when stdout is a TTY (an interactive terminal, not a pipe or file redirect where ANSI codes would pollute the output). Useful for opting into auto-off when piping: new Logger({ colors: supportsColor() }).
Returns
boolean