Skip to content

-bash: react-native: command not found

tl;dr
Error: -bash: react-native: command not found
Solution: /Users/*username*/.npm-packages/bin

Whenever I tried to init a new react-native app I got the error: “command not found“. As it has worked in the past I started my search in the wrong direction and it took me way to long to find out it was the npm bin path that needed to be added to my PATH, so for all of you in search for a solution:

export PATH="/Users/*username*/.npm-packages/bin:$PATH"

Adding this path did the trick for me.

Happy coding!

Published inCode