Install npm times -4048 error solution

Use npm install express -g to report the following errors and several solutions

solution:

1. Modify the folder permissions under the installation path. I installed it under D:\NodeJs here , so just modify the folder permissions of NodeJs.

2. Delete the .npmrc file. The file is located in C:\Users\{username}\.npmrc, for example, the username of . The file is located in C:\Users\qingpeng\.npmrc;

The solution is as follows, and the package can be installed normally!

Guess you like

Origin blog.csdn.net/weixin_52890053/article/details/130880761