npm / @antfu/ni
@antfu/ni
What changed in @antfu/ni 26 to 30, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-19.
2 breaking11 new APIs and options1 behavior and defaults7 tooling11 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli init@antfu/ni 3019 changes
Breaking changes 1
Node.js >=20.19.0 is now required to use @antfu/ni.
New APIs and options 6
Adds an existing mode that only reuses existing catalog entries.
Adds support for nub as a package manager.
Adds a flag to prefer local binaries.
Adds the --agent flag to print the detected package manager name.
Adds the ? dry-run flag to the --help output.
Adds the noLastCommand configuration option for nr.
Behavior and default changes 1
Reuses the previous catalog choice when installing multiple packages.
Tooling 4
Supports bun catalogs, allowing @antfu/ni to work with projects that use them.
Adds support for aube as a package manager.
Support yarn catalogs.
Dependencies in package.json are sorted alphabetically, making dependency lists consistent.
Fixes and other changes 7
Splits name@version before using it as a catalog key.
Warns about unreadable and unrecognised .nirc options.
Reads package.json files written in JSONC.
Detection of --agent is non-interactive.
Preserves forwarded -p arguments.
System package manager binaries are preferred.
Fixes workspace flag parsing in the nr command.
@antfu/ni 291 changes
Tooling 1
Adds support for pnpm catalogs.
@antfu/ni 287 changes
Breaking changes 1
nun uses multi-select by default.
New APIs and options 2
The CLI supports the --programmatic flag in its arguments.
Run tasks before agent detection.
Tooling 1
Fish shell completion support was added for nr.
Fixes and other changes 3
Prevent the agent prompt when using completion flags.
Corrects the command structure used by nr with node --run.
Pressing ESC now cancels nr in interactive mode.
@antfu/ni 273 changes
New APIs and options 2
Adds the
ndcommand.Adds support for Node.js
--runwhen usingnr.
Fixes and other changes 1
Ctrl+C is handled during interactive installs.
@antfu/ni 262 changes
New APIs and options 1
Adds sfw integration, allowing developers to use ni with sfw.
Tooling 1
Adds support for Bun's new interactive upgrade command.