ionic-team / capacitor-assets

Local Capacitor icon/splash screen resource generation tool
MIT License
506 stars 99 forks source link

cannot install @capacitor/assets #584

Closed bitekas closed 9 months ago

bitekas commented 9 months ago
npm install --save-dev @capacitor/assets

results in

npm ERR! code E404
npm ERR! 404 Not Found - GET https://npm.pkg.github.com/@capacitor%2fassets - npm package "assets" does not exist under owner "capacitor"
npm ERR! 404 
npm ERR! 404  '@capacitor/assets@*' is not in this registry.
npm ERR! 404 
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

npm ERR! A complete log of this run can be found in: [HOME]/.npm/_logs/2023-12-13T08_54_38_419Z-debug-0.log

Log file content contains the same error. It looks like there is a problem with package visibility.

Tested on the 13'th of December 2023 with npm v.v. 9.8.1 and 10.2.3, Asia and Oceania region.

jcesarmobile commented 9 months ago

That's correct, the package is published in https://registry.npmjs.org, not in https://npm.pkg.github.com. You'll have to configure npm to use the default registry (https://registry.npmjs.org), and not the github registry.

If you need github registry for some packages you can configure npm by using a .npmrc file to tell npm where to search certain packages, in example for all @capacitor packages use npm registry like this: @capacitor:registry=https://registry.npmjs.org