mirror of https://github.com/status-im/metro.git
Add a flush() function to Terminal
Reviewed By: yungsters Differential Revision: D6713011 fbshipit-source-id: 05afd49e4099301124d83e1b345d7b40a9c84c73
This commit is contained in:
parent
5d3581e795
commit
2e34f6f9a8
|
@ -169,6 +169,13 @@ class Terminal {
|
|||
this.log(this._nextStatusStr);
|
||||
this._nextStatusStr = '';
|
||||
}
|
||||
|
||||
flush(): void {
|
||||
// Useful if you're going to start calling console.log/console.error directly
|
||||
// again; otherwise you could end up with mangled output when the queued
|
||||
// update starts writing to stream after a delay.
|
||||
this._scheduleUpdate.flush();
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = Terminal;
|
||||
|
|
Loading…
Reference in New Issue