enableLogs static method

void enableLogs({
  1. LogHandler? handler,
})

Makes logs visible. If logs are enabled, you will able to see logs from different structures of the package. For example, event logs from ConnectionDelegates.
Logs are done with handler if specified. Otherwise, they will be printed to console using print.

Implementation

static void enableLogs({LogHandler? handler}) {
  if (handler != null) {
    _handler = handler;
  } else {
    _handler = print;
  }

  _logsEnabled = true;
}