Problems encountered today :( These are just examples)
Solution:
npm clean cache --force
Deleted node_modules and package-lock, then npm install
If there is not, take a look at this modulle npm needed ah what the hell's version meets the version of your computer.
Non-compliance with the upgrade.
It is recommended that one of the best, most hassle free method:
First, open the Windows PowerShell software (open to the administrator), then: Execute the following command to upgrade all!
Windows PowerShell 版权所有 (C) Microsoft Corporation。保留所有权利。 PS C:\Windows\system32> Set-ExecutionPolicy Unrestricted -Scope CurrentUser -Force PS C:\Windows\system32> npm install -g npm-windows-upgrade F:\nodejs\npm-windows-upgrade -> F:\nodejs\node_modules\npm-windows-upgrade\bin\npm-windows-upgrade.js + [email protected] added 72 packages in 14.766s PS C:\Windows\system32> npm-windows-upgrade npm-windows-upgrade v6.0.1 ? Which version do you want to install? 6.10.2 Checked system for npm installation: According to PowerShell: F:\nodejs According to npm: F:\nodejs Decided that npm is installed in F:\nodejs Upgrading npm... / Upgrading npm (fallback method)... \ You wanted to install npm 6.10.2, but the installed version is 6.9.0. A common reason is an attempted "npm install npm" or "npm upgrade npm". As of today, the only solution is to completely uninstall and then reinstall Node.js. For a small tutorial, please see https://github.com/felixrieseberg/npm-windows-upgrade#usage. Please consider reporting your trouble to https://aka.ms/npm-issues. Debug Information: http_parser: 2.8.0 | node: 8.11.0 | v8: 6.2.414.50 | uv: 1.19.1 | zlib: 1.2.11 | ares: 1.10.1-DEV | modules: 57 | nghttp2: 1.25.0 | openssl: 1.0.2o | icu: 60.1 | unicode: 10.0 | cldr: 32.0 | tz: 2017c | os: win32 x64 PS C:\Windows\system32> npm-windows-upgrade -p -v latest npm-windows-upgrade v6.0.1 Checked system for npm installation: According to PowerShell: C:\Users\XiaoYe\AppData\Roaming\npm According to npm: F:\nodejs Decided that npm is installed in C:\Users\XiaoYe\AppData\Roaming\npm Upgrading npm... Upgrade finished. Your new npm version is 6.10.3. Have a nice day! PS C:\Windows\system32>
Successful upgrade, and then try again
npm clean cache --force
Deleted node_modules and package-lock, then npm install, then npm run dev look.