Skip to content

Node.js versions

Most PHP projects also need a JavaScript toolchain — for Vite, asset builds, or a front-end dev server. Butler manages Node.js versions for you through fnm, so you don’t need a separate Node manager.

Node support comes from the fnm component. Install it once, then install the Node versions you want:

Terminal window
butler install fnm
butler fnm install 22 # install the latest Node 22.x
butler fnm install 20

Set a default version:

Terminal window
butler fnm default 22

The Node section of the menu bar app shows your installed versions with a picker to install more or change the default — the same actions without the terminal.

Butler exposes the active Node toolchain through its own subcommands, so they use the version Butler manages regardless of what’s otherwise on your PATH:

Terminal window
butler node -v
butler npm install
butler npx vite build

If you’d rather call node, npm, php and composer directly (without the butler prefix), install Butler’s shell integration:

Terminal window
butler shell install

This hooks your shell so Butler’s php, fnm/Node, and Composer are on your PATH, with per-directory version switching. Check what’s resolving with:

Terminal window
butler which node