UNPKG

miter

Version:

A typescript web framework based on ExpressJs based loosely on SailsJs

20 lines 767 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const nativeReadline = require("readline"); const wrap_promise_1 = require("../util/wrap-promise"); function translateClearDirection(dir) { if (dir == 'left') return -1; else if (dir == 'right') return 1; else return 0; } exports.cout = { clearLine: (dir = 'entire') => nativeReadline.clearLine(process.stdout, translateClearDirection(dir)), cursorTo: (x, y) => nativeReadline.cursorTo(process.stdout, x, y), moveCursor: (dx, dy) => nativeReadline.moveCursor(process.stdout, dx, dy), write: (str) => wrap_promise_1.wrapPromise(process.stdout.write.bind(process.stdout), str), native: nativeReadline }; //# sourceMappingURL=cout.js.map