Replies: 1 comment 4 replies
-
In the context of how widely this would be adopted and given the interface need to be different (e.g a fair amount of code), I'm not initially inclined to introduce this within the existing prompt packages. I'd suggest starting this as a separate package (happy to link to it from Inquirer's README.) And we can review that decision at a later point based on adoption numbers. |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi Inquirer team 👋
Thanks for building such a great library — I’ve used it many times in full-featured CLI tools, and it’s always a pleasure to work with.
I’d love to propose exposing standalone CLI binaries for each prompt type (e.g.
@inquirer/select
,@inquirer/input
, etc), so they can be used directly in bash scripts or one-liners:✅ Example usage
This would yield a nice interactive prompt and echo the selected value. It’s a huge quality-of-life improvement over traditional bash.
🌚 Bash comparison
Current (bash built-in):
Proposed (Inquirer-style):
Much cleaner, and with better UX (arrows, search, consistent behaviour across platforms).
🔧 Implementation idea
Each package could expose a binary:
@inquirer/input
– for text input@inquirer/select
– for single choice@inquirer/checkbox
– for multi-select@inquirer/confirm
– for yes/noEach binary would:
--message
,--default
, etc.💡 Why this matters
This would make Inquirer incredibly useful for:
read
/select
prompts in bashHappy to help with a prototype or PR if this sounds worth exploring!
Thanks again 🙌
Beta Was this translation helpful? Give feedback.
All reactions