12 lines
309 B
TypeScript
12 lines
309 B
TypeScript
|
import { AnsiTerminalDisplay } from "./ansi.ts";
|
||
|
import { TextUI } from "./ui.ts";
|
||
|
export { TextUI } from "./ui.ts";
|
||
|
|
||
|
export async function createTextUI(): Promise<TextUI> {
|
||
|
// TODO detect platform
|
||
|
var display = new AnsiTerminalDisplay();
|
||
|
var ui = new TextUI(display);
|
||
|
await ui.init();
|
||
|
return ui;
|
||
|
}
|