Deveco Studio Install JS 3.1.0.0 failed.

Deveco Studio初始配置时报错

Error: : Install JS 3.1.0.0 failed. Error: : Install JS dependencies failed. Cause: Unable to run npm install. Solution: See https://developer.harmonyos.com/cn/docs/documentation/doc-guides/f aq-development-environment-0000001168829643#section1311117111474

解决方法:

打开cmd终端,输入npm install 看下有没有报错 C:UsersWincent>npm install npm WARN saveError ENOENT: no such file or directory, open C:UsersWincentpackage.json npm WARN enoent ENOENT: no such file or directory, open C:UsersWincentpackage.json npm WARN Wincent No description npm WARN Wincent No repository field. npm WARN Wincent No README data npm WARN Wincent No license field.

//提示这个以后我删掉C:UsersWincentpackage.json //反手把.npmrc, .npmrc-bak-xxx文件也删除了,再retry就可以了

C:UsersWincent>npm install npm WARN saveError ENOENT: no such file or directory, open C:UsersWincentpackage.json npm notice created a lockfile as package-lock.json. You should commit this file. npm WARN enoent ENOENT: no such file or directory, open C:UsersWincentpackage.json npm WARN Wincent No description npm WARN Wincent No repository field. npm WARN Wincent No README data npm WARN Wincent No license field.

经验分享 程序员 微信小程序 职场和发展