Node
A quick refresher course about Node topics.
Multiple versions of node
nodenv works reasonably well. Installation is simple with brew install nodenv node-build
.
To install new node version, use node install -l
to list available versions and node install <version>
to install it.o
After installation, nodenv versions
will list all the installed versions.
The nodenv local
inside your project will set a .node_version
file in the current directory that will make sure you always use that version of node while inside this directory. Use nodenv global
to set the global default version of node.
To temporary switch to a specific node version, use nodenv shell <version>
to enable.
All commands, shell
, local
and global
also allow for an --unset
option to undo the action.
If you want to find a specific command installed on one of your node versions, nodenv whence <command>
will display the versions that have it, pretty nice.