As MacOS switched to zsh replacing bash a while back (you may have noticed the prompt to change to zsh in your Terminal), I keep coming across a few issues that I need to work around. My latest was that I noticed apps I’d installed globally with ‘npm install -g’ were no longer in my path.
Following a combination of suggestions from answers to this question, I added the following line to ~/.zshrc to add the npm global install dir to my path:
export PATH="$PATH:$HOME/.npm-global/bin"