(opts: InputConfig | string)
| 62 | export async function input(opts: InputConfig): Promise<string>; |
| 63 | |
| 64 | export async function input(opts: InputConfig | string): Promise<string> { |
| 65 | if (typeof opts === "string") { |
| 66 | opts = { message: opts }; |
| 67 | } else { |
| 68 | const { shouldReturn, value } = guard(opts); |
| 69 | if (shouldReturn) { |
| 70 | return value; |
| 71 | } |
| 72 | } |
| 73 | return inquirer.input(opts); |
| 74 | } |
| 75 | |
| 76 | /** |
| 77 | * Options for the confirm function. |
no test coverage detected
searching dependent graphs…