Error: Cannot find module ‘commander‘

created at 07-04-2021 views: 3

description

error message

Error: Cannot find module 'commander'

reason

Check the prompt of the vue-cli version, the module commander cannot be found

Solution

Method 1

Reinstall commander:npm install commander --save

Important reminder: Do not install in the directory where node is installed, otherwise it will not work;

Method 2

Install vue-cli globally,

Hint: But I tried it to no avail

Please log in to leave a comment.