0

I wanted to install canvas, but it seems that despite having a node in my PATH, I can't seem to install it because it can't recognize anything involving npm or node-gyp.

Git Bash and other terminals recognize npm and node-gyp, but I still can't install canvas or use npm in the base cmd.exe.

Sohail Ahmad
  • 7,309
  • 5
  • 27
  • 46
Zyxophobia
  • 13
  • 1
  • 9

1 Answers1

0

Firstly have you tried this 'npm' is not recognized as internal or external command, operable program or batch file

Tried installing canvas on my end and npm works fine on cmd.exe.

I am using Win10 Pro & have installed node globally.

Check if you can run node -v

Its always best to ensure that you are running the LTS version of node.

I'm a little confused, if its working with git bash and other terminals, whats the fuss on using windows cmd?

  • I feel like that the issue with installing canvas is due to Windows cmd not recognizing npm. I'll try what was suggested in the hyperlinked text, and will reply with my results. – Zyxophobia Mar 16 '20 at 15:26
  • After testing, it turns out that I still can't use it. I can run `node -v` just fine, but even after opening the Nodejs Command Prompt, I still can't use npm. – Zyxophobia Mar 16 '20 at 15:30