printError function

void printError(
  1. String text
)

Prints text to the console as an error message with red color.

Implementation

void printError(String text) {
  print('\x1B[31m$text\x1B[0m');
}