initializeTUI function

void initializeTUI({
  1. bool noTui = false,
})

Initialize the TUI system with a logger instance

This should be called once at application startup. The noTui parameter can be used to disable TUI features globally.

Implementation

void initializeTUI({bool noTui = false}) {
  _tuiEnabled = !noTui && _isTTY();

  tuiLogger = Logger(
    level: _tuiEnabled ? Level.info : Level.info,
    theme: _getLoggerTheme(),
  );
}