. Advertisement .
..3..
. Advertisement .
..4..
Hi everyone, i’m getting the error “cannot find module semver”. I’ve tried a lots, but i can’t fix it. As following this below:
PS C:\Users\wangting\Desktop\Wisdom_admin\wisdom_admin> npm run dev
> [email protected] dev C:\Users\wangting\Desktop\Wisdom_admin\wisdom_admin
> vue-cli-service serve
internal/modules/cjs/loader.js:985
throw err;
^
Error: Cannot find module 'semver'
Require stack:
- C:\Users\wangting\Desktop\Wisdom_admin\wisdom_admin\node_modules\_@[email protected]@@vue\cli-service\bin\vue-cli-service.js
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:982:15)
at Function.Module._load (internal/modules/cjs/loader.js:864:27)
at Module.require (internal/modules/cjs/loader.js:1044:19)
at require (internal/modules/cjs/helpers.js:77:18)
at Object.<anonymous> (C:\Users\wangting\Desktop\Wisdom_admin\wisdom_admin\node_modules\_@[email protected]@@vue\cli-service\bin\vue-cli-service.js:3:16)
at Module._compile (internal/modules/cjs/loader.js:1158:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10)
at Module.load (internal/modules/cjs/loader.js:1002:32)
at Function.Module._load (internal/modules/cjs/loader.js:901:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12) {
code: 'MODULE_NOT_FOUND',
requireStack: [
This is my big test, I’m looking forward to answering of everyone soon!
The cause:
Version issues.
The solution:
I solve my problem with these steps:
1. Wipe
node_modules.
2. Then you have to add the vscode editor, the terminal which is the open’s secondly , the project directory is finished, put dependencies.
3. This programme is restarted:
I hope you will fix this error. Good luck!