npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

interactive-cli-menu

v1.0.1

Published

A sleek and customizable CLI menu with arrow key navigation and actions. No external dependencies!

Maintainers

ddosnotificationddosnotification

Keywords

climenuinteractiveterminalcommand-linenpm-packagecli-menuterminal-uicli-toolcommand-line-interfacenodejsnodejs-menumenu-systeminteractive-cliconsoleterminal-appnode-cliterminal-navigationarrow-navigationmenu-navigationcli-navigationconsole-menucommand-line-menucustomizable-menuterminal-appsinteractive-menunode-menucommand-line-interface-menucli-toolkitterminal-navigation-menuinteractive-uistylish-menuascii-menutext-menustyled-cli-menunpm-cli-menucli-interfacearrow-key-navigationno-dependency-menuminimal-cli-menulightweight-cli-menucolor-menuconsole-navigationtext-uiterminal-applicationcli-apptext-interfacekeyboard-navigationcli-navigation-utilitycustom-cli-menunodejs-terminalmodern-cli-menuterminal-ui-libraryterminal-toolcli-widgetcommand-line-widgetcli-navigation-systemconsole-toolinteractive-cli-toolnode-cli-toolcommand-line-navigationcli-navigatorarrow-navigatorterminal-selectorcustom-navigationterminal-stylingstyled-terminalmenu-navigation-toolterminal-interactioncli-interactive-toolcli-menu-buildercli-app-buildercli-app-uicli-menu-systemactionable-menustylish-cli-navigationcli-colorterminal-colorcli-keyboard-navigationconsole-action-menuinteractive-terminalterminal-ui-systemterminal-menu-builderinteractive-command-linenode-terminalarrow-menuconsole-navigation-toolcli-componentcommand-line-componentnpm-terminal-menunpm-command-linecommand-line-action-menudynamic-cli-menuinteractive-CLInode-terminal-menucli-projectcommand-line-appstylish-command-lineconsole-menu-systemcli-interface-libraryconsole-actionable-menucli-keyboard-interfaceaction-menuinteractive-navigatornode-terminal-toolcommand-line-interface-libraryCLI-librarynpm-cli-navigationcli-interactionstylish-command-line-menuterminal-inputcli-input-handlerterminal-interaction-systemdynamic-menumenu-buildercommand-line-utilityterminal-utilityterminal-UI-componentcli-project-toolinteractive-CLI-menustylish-command-line-interfacenode-cli-navigationcommand-line-stylingcli-utilitycli-stylenodejs-navigationterminal-styling-toolkeyboard-menucommand-line-styling-toolcommand-line-interactionstylish-cli-toolcommand-line-keyboard-navigationactionable-cliterminal-UI-navigationcli-uxux-cliterminal-ux-toolcli-ux-menuCLI-UX-interfacecommand-line-UXinteractive-CLI-toolkitcli-menu-UXterminal-action-menuCLI-UI-systemUX-CLI-toolstylish-command-line-toolcli-project-menumenu-system-clistylish-menu-builderactionable-terminal-menustylish-terminal-appinteractive-CLI-appCLI-menu-systemcommand-line-navigation-toolUX-menucommand-line-menu-buildermenu-systemnodejs-uiUX-interfaceterminal-menu-systemCLI-navigationterminal-interaction-toolCLI-menu-navigationterminal-UX-interfacecli-command-toolterminal-interface-builderCLI-systemterminal-app-builder

Readme

🌟 interactive-cli-menu

npm version downloads GitHub stars

interactive-cli-menu is a sleek, modern, and customizable NPM package for creating interactive CLI menus. It supports smooth arrow key navigation, actionable items, and beautiful terminal UI—all without external dependencies! Perfect for making your command-line tools pop! 🎉


🚀 Features

  • 🔼 Arrow Key Navigation: Effortlessly navigate menus with the up/down arrows.
  • 🎨 Customizable Styling: Choose colors, widths, borders, and more.
  • Actionable Items: Attach custom actions to menu selections.
  • 🪶 Lightweight: No external dependencies—100% native Node.js.
  • 🛑 Graceful Exit: Cleanly handles Ctrl+C to terminate.

📦 Installation

Install via NPM:

npm install interactive-cli-menu

🛠️ Usage

✨ Simple Example

const { createMenu } = require('interactive-cli-menu');

const menu = createMenu({
  title: '🍔 Main Menu',
  width: 50,
  borderColor: 36, // Cyan
  highlightColor: 33, // Yellow
  textColor: 37, // White
  items: [
    { label: '🔍 Search', action: () => console.log('Searching... 🔎') },
    { label: '⚙️ Settings', action: () => console.log('Opening settings... 🛠️') },
    { label: '❌ Exit', action: () => console.log('Goodbye! 👋') }
  ]
});

menu.render();

🖥️ Output

──────────────────────────────────────────────────
                   🍔 Main Menu
──────────────────────────────────────────────────

  🔍 Search
> ⚙️ Settings
  ❌ Exit

──────────────────────────────────────────────────

Interact:

  • Use ⬆️ Up and ⬇️ Down to navigate.
  • Press ⏎ Enter to select.

🎨 API

createMenu(options)

options (object)

| Option | Type | Default | Description | |------------------|----------|---------------|-----------------------------------------------------------------------------| | title | string | 'Menu' | Title displayed at the top of the menu. | | width | number | 60 | Width of the menu in characters. | | borderColor | number | 90 (Gray) | ANSI color code for the border. | | highlightColor | number | 34 (Blue) | ANSI color code for the selected menu item. | | textColor | number | 37 (White) | ANSI color code for unselected menu items. | | items | array | [] | Array of menu items (see below). |


Menu Items (items)

Each item is an object with the following properties:

| Property | Type | Description | |------------|------------|--------------------------------------------------------| | label | string | The text displayed for the menu item (supports emojis).| | action | function | The function executed when the item is selected. |


🌟 Advanced Example: Dynamic Menus with Emojis

const { createMenu } = require('interactive-cli-menu');

let items = [
  { label: '📄 View Files', action: () => console.log('Listing files... 🗂️') },
  { label: '➕ Add Item', action: () => console.log('Adding item... ✅') },
  { label: '❌ Exit', action: () => console.log('Goodbye! 👋') }
];

const menu = createMenu({
  title: '🛠️ My CLI Tool',
  width: 60,
  borderColor: 35, // Magenta
  highlightColor: 32, // Green
  textColor: 37, // White
  items
});

menu.render();

🛣️ Roadmap

🔮 Future Enhancements:

  • 📂 Nested Menus: Add support for multi-level menus.
  • 🌈 Extended Themes: More built-in color schemes and styles.
  • 🕵️ Search: Enable searchable menus for longer lists.
  • ⌨️ Custom Keybindings: Allow custom navigation keys.

🙌 Contributing

We ❤️ contributions! If you find a bug or have an idea for improvement, feel free to open an issue or submit a pull request.


📄 License

interactive-cli-menu is open-source and available under the MIT License.


Make your CLI tools stylish and user-friendly with interactive-cli-menu! 🌟