@inquirer/number
4.3.1 · 22 Nov 2026MIT56.2M / weekRepositoryHomepagenpmAtom feed
4.3.1 is the newest release of 4.x.
Summary· from the note as AI read it
Migration neededRead before upgrading: 2 changes to make.
Before you upgrade
- Custom validate functions must now handle undefined for empty optional answers
New minimums
- Upgrade to Node.js 22 or later
In short
1 breaking1 removed
- Breaking
Optional number prompts left empty now call
validatewithundefined— a custom validator can reject or accept an empty answer (this restores the pre-4.0.11 behavior; built-in range checks still run first) - Removed
Node.js 20 is no longer supported; the minimum is now Node 22
Release note
The section about @inquirer/number of a note shared by several packages.
@inquirer/number@4.3.0
What's new
Optional number prompts left empty now call
validatewithundefined— a custom validator can reject or accept an empty answer (this restores the pre-4.0.11 behavior; built-in range checks still run first)Node.js 20 is no longer supported; the minimum is now Node 22
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.