Error picture
reason
Maybe the nodejs version is too high
Solution
To reduce the nodejs version, I chose to 14.13.1
install vue-cli after installing version 14.13.1, and an error was reported:npm ERR! Error: EACCES: permission denied, access '/usr/local/lib/node_modules'
This is mainly because I am using a mac, which generally requires administrator privileges when installing certain software.
So just add it before the command sube
, for example:
sudo npm install -g @vue/cli
Successful installation: