Installation
npm install --save @types/yargs-interactive
Summary
This package contains type definitions for yargs-interactive (https://github.com/nanovazquez/yargs-interactive#readme).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/yargs-interactive.
index.d.ts
import { Argv } from "yargs";
declare function yargsInteractive(): yargsInteractive.Interactive;
declare namespace yargsInteractive {
interface OptionData {
type: "input" | "number" | "confirm" | "list" | "rawlist" | "expand" | "checkbox" | "password" | "editor";
describe: string;
default?: string | number | boolean | any[] | undefined;
prompt?: "always" | "never" | "if-no-arg" | "if-empty" | undefined;
choices?: string[] | undefined;
}
interface Option {
[key: string]: OptionData | { default: boolean };
}
interface Interactive extends Argv {
usage(usage: string): Interactive;
interactive(options: Option): Interactive;
then(callback: (result: any) => any): Interactive;
}
}
export = yargsInteractive;
Additional Details
- Last updated: Tue, 07 Nov 2023 15:11:36 GMT
- Dependencies: @types/yargs
Credits
These definitions were written by Nano Vazquez.