Function: createInterface()
createInterface(
options):ReadlineInterface
Create a new readline interface.
Parameters
options
Configuration options.
Returns
Example
import { createInterface } from 'tjs:readline';
const rl = createInterface({
input: tjs.stdin,
output: tjs.stdout,
prompt: '> ',
});
for await (const line of rl) {
rl.write(`You said: ${line}\n`);
}
rl.close();