*cnpm installation in windows environment depends on vue front-end project construction*

cnpm installation depends on vue front-end project construction in windows environment

one. .Install npm install nrm -g dependency error message

npm ERR! code ECONNRESET
npm ERR! syscall read
npm ERR! errno ECONNRESET
npm ERR! network request to https://registry.npmjs.org/package failed, reason: read ECONNRESET
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network ‘proxy’ config is set properly. See: ‘npm help config’

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Administrator\AppData\Local\npm-cache_logs\2022-03-29T16_20_05_831Z-debug-0.log

D:\Program Files>npm install package@latest --save
npm ERR! code ECONNRESET
npm ERR! syscall read
npm ERR! errno ECONNRESET
npm ERR! network request to https://registry.npmjs.org/package failed, reason: read ECONNRESET
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network ‘proxy’ config is set properly. See: ‘npm help config’

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Administrator\AppData\Local\npm-cache_logs\2022-03- 29T16_22_18_637Z-debug-0.log
1. Execute the command npm config set proxy http://:
2.< /span> 6. If you encounter the following error: 5. Open windows Powershell cd to the directory where you want to create the project 4. Insert vue cli: npm install -g @vue/cli
3. Check whether the image is installed: nrm ls Now execute npm install nrm -g and try again. Location Line: 1 Character: 1





  • vue create yeb
  •   + CategoryInfo          : ObjectNotFound: (vue:String) [], CommandNotFoundException
      + FullyQualifiedErrorId : CommandNotFoundException
     6.1 执行set-ExecutionPolicy RemoteSigned   然后选择y
    

Execution policy changes
Execution policies help you prevent untrusted scripts from being executed. Changing execution policies can create security risks, as described in the about_Execution_Policies help topic at https://go.microsoft.com/fwlink/?LinkID=135170
. Do you want to change the execution policy?
[Y] Yes (Y) [A] All yes (A) [N] No (N) [L] All no (L) [S] Suspend ( S) [?] Help (default value is "N"): Y
7. Verify whether it is successful: enter get-ExecutionPolicy, the system will reply Restricted, indicating that the status is prohibited.
If RemoteSigned is prompted, it means success.

Guess you like

Origin blog.csdn.net/weixin_47062100/article/details/123836320