close method
Stops reading and restores the terminal modes. Safe to call more than once.
Implementation
Future<void> close() async {
if (_closed) return;
_closed = true;
await _sub?.cancel();
if (interactive) _setRawMode?.call(false);
}
Stops reading and restores the terminal modes. Safe to call more than once.
Future<void> close() async {
if (_closed) return;
_closed = true;
await _sub?.cancel();
if (interactive) _setRawMode?.call(false);
}