I'm not really familiar with the new z shell and not really a terminal power user, however, I'm familiar with package managers and as I was trying to install a package globally using npm install x -g, it installs successfully but I can't use the command and I get the following error
zsh: command not found: x
Echoing $PATH shows the following value
/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/VMware Fusion.app/Contents/Public:/Users/(user)/.npm-global/bin
I don't have a .zshrc file to edit, I'm not sure that's the default thing or not but this is a fresh installation of mac os