snake-cli-ts
Version:
Nodejs cli snake game
22 lines (21 loc) • 570 B
TypeScript
import CLIMenu from '.';
export interface IMenuOptions {
name?: string;
disabled?: boolean;
value?: any;
submenu?: IMenuOptions[];
callback?: (this: MenuOption) => void;
onInit?: (this: MenuOption) => void;
}
export default class MenuOption {
menu: CLIMenu;
name: string;
disabled: boolean;
value: any;
submenu?: CLIMenu;
_callback?: (this: MenuOption) => void;
onInit?: (this: MenuOption) => void;
constructor(settings: IMenuOptions, menu: CLIMenu);
callback(): void;
back(): void;
}