Solve the problem of using vue ui to create a project and report an error when starting the project
I use vue ui to create a project, but when I start the project, the error is reported as follows:
This relative module was not found: * ./src/main.js in multi ……
but the npm run server
project can be started normally by starting the project through the terminal command. I checked a lot of information on the Internet, but the problem cannot be solved.
The following are the steps to solve the problem:
1. After vue -V
checking the version of vue-cli, it is found that the version is 4.3.1, which is relatively low;
2. Checked the update record of vue-cli official website and found that the latest version has reached 4.5.8;
3, through npm update -g @vue/cli
to the latest version, create a project and start the project successfully updated vue-cli again!
Summary:
Use vue ui to create a project. When starting the project, the error is reported as follows: The
This relative module was not found: * ./src/main.js in multi ……
main reason is that the version of vue-cli is low. You can solve this problem by upgrading the vue-cli version.