-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.d.ts
45 lines (42 loc) · 1.01 KB
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
declare namespace ReadPromise {
interface Options {
/**
* What to write to stdout before reading input.
*/
prompt: string;
/**
* The default value if the user enters nothing.
*/
default?: string;
/**
* Replace silenced characters with the supplied character value.
*/
replace?: string;
/**
* Readable stream to get input data from. (default process.stdin)
*/
input?: any;
/**
* Writeable stream to write prompts to. (default: process.stdout)
*/
output?: any;
/**
* Number of ms to wait for user input before giving up.
*/
timeout?: number;
/**
* Allow the user to edit the default value.
*/
edit?: boolean;
/**
* Treat the output as a TTY, whether it is or not.
*/
terminal?: boolean;
/**
* Don't echo the output as the user types it.
*/
silent?: boolean;
}
}
declare function ReadPromise(options: string | ReadPromise.Options): Promise<string>;
export = ReadPromise;