npm ERR code ENOSELF npm ERR Refusing to install package with name package under a package

NPM installation error

npm ERR! code ENOSELF
npm ERR! Refusing to install package with name "package" under a package
npm ERR! also called "package". Did you name your project the same
npm ERR! as the dependency you're installing?
npm ERR!
npm ERR! For more information, see:
npm ERR!     <https://docs.npmjs.com/cli/install#limitations-of-npms-install-algorithm>

Match another picture:
npm ERR!
Solution:

Let's check the in our folderpackage.jsonAnd look foranswer

package.json

We will find that the package name to be downloaded by npm is different from the name in package.json name

So this happens, so let's try again after changing the name!
Then okay

package.json name

Guess you like

Origin blog.csdn.net/weixin_43814775/article/details/106485954